FramesSingleDeprecated

General Interface 3.8
API Documentation

Packages
Global GI static methods and constants.
The General Interface Asynchronous Modular Platform (AMP).
The standard library of AMP application utility classes.
Application layer classes.
Various Charting related constants and utility functions.
GUI classes.
Utility methods related to rendering HTML.
The public API of the General Interface IDE.
Base classes and the GI introspection framework.
Networking related classes.
Utility classes.
This package and all contained classes are available only when the Charting add-in is enabled.
XML related classes.
Top-Level properties and functions.

package jsx3

Global GI static methods and constants.

Class Summary
jsx3.$Array
Useful extensions to the JavaScript Array class.
jsx3.$AsyncCB
The callback object passed as the single argument to an asynchronous method.
jsx3.$AsyncRV
The return value from an asynchronous method.
jsx3.$Function
Useful extensions to the JavaScript Function class.
jsx3.$Hash
Useful extensions to the JavaScript Object class for emulating a hashtable.
jsx3.$Object
Useful extensions to the JavaScript Object class.
jsx3.$String
Useful extensions to the JavaScript String class.
jsx3.Alerts
Deprecated. Renamed to jsx3.gui.Alerts.
jsx3.Block
Deprecated. Renamed to jsx3.gui.Block
jsx3.BlockX
Deprecated. Renamed to jsx3.gui.BlockX. Most functionality of this class was moved into a new interface, jsx3.xml.Cacheable.
jsx3.Boolean
Boolean class encapsulates GI's XML boolean values (0 and 1 rather than true and false).
jsx3.Button
Deprecated. Renamed to jsx3.gui.Button
jsx3.CDF
Deprecated. Renamed to jsx3.xml.CDF
jsx3.Cache
Deprecated. Renamed to jsx3.app.Cache
jsx3.CheckBox
Deprecated. Renamed to jsx3.gui.CheckBox
jsx3.Collection
Deprecated. Subsumed by jsx3.util.List.
jsx3.Column
Deprecated. Renamed to jsx3.gui.Column
jsx3.DOM
Deprecated. Renamed to jsx3.app.DOM
jsx3.DatePicker
Deprecated. Renamed to jsx3.gui.DatePicker
jsx3.Dialog
Deprecated. Renamed to jsx3.gui.Dialog
jsx3.Document
Deprecated. Renamed to jsx3.xml.Document
jsx3.ERROR
Deprecated. Renamed to jsx3.util.Logger
jsx3.EVT
Deprecated. Use class jsx3.gui.Event instead.
jsx3.Entity
Deprecated. Renamed to jsx3.xml.Entity
jsx3.Event
Deprecated. Renamed to jsx3.gui.Interactive
jsx3.EventDispatcher
Deprecated. Renamed to jsx3.util.EventDispatcher
jsx3.Form
Deprecated. Renamed to jsx3.gui.Form
jsx3.Grid
Deprecated. Renamed to jsx3.gui.Grid
jsx3.Heavyweight
Deprecated. Renamed to jsx3.gui.Heavyweight
jsx3.HttpForm
Deprecated. Renamed to jsx3.net.Form
jsx3.HttpRequest
Deprecated. Renamed to jsx3.net.Request
jsx3.LayoutGrid
Deprecated. Renamed to jsx3.gui.LayoutGrid
jsx3.List
Deprecated. Renamed to jsx3.gui.List
jsx3.Menu
Deprecated. Renamed to jsx3.gui.Menu
jsx3.Model
Deprecated. Renamed to jsx3.app.Model
jsx3.RadioButton
Deprecated. Renamed to jsx3.gui.RadioButton
jsx3.Select
Deprecated. Renamed to jsx3.gui.Select
jsx3.Server
Deprecated. Renamed to jsx3.app.Server
jsx3.Service
Deprecated. Renamed to jsx3.net.Service
jsx3.Settings
Deprecated. Renamed to jsx3.app.Settings
jsx3.Slider
Deprecated. Renamed to jsx3.gui.Slider
jsx3.Splitter
Deprecated. Renamed to jsx3.gui.Splitter
jsx3.Stack
Deprecated. Renamed to jsx3.gui.Stack
jsx3.StackGroup
Deprecated. Renamed to jsx3.gui.StackGroup
jsx3.Tab
Deprecated. Renamed to jsx3.gui.Tab
jsx3.TabbedPane
Deprecated. Renamed to jsx3.gui.TabbedPane
jsx3.TextBox
Deprecated. Renamed to jsx3.gui.TextBox
jsx3.ToolbarButton
Deprecated. Renamed to jsx3.gui.ToolbarButton
jsx3.Tree
Deprecated. Renamed to jsx3.gui.Tree
jsx3.UserSettings
Deprecated. Renamed to jsx3.app.UserSettings
jsx3.WindowBar
Deprecated. Renamed to jsx3.gui.WindowBar
Field Summary
static String
Deprecated. Use jsx3.getEnv("jsxabspath").
static String
location for addin resources.
static String
Deprecated. Use jsx3.getEnv("jsxhomepath").
static jsx3.app.Cache
Deprecated. Use getSharedCache() instead.
static jsx3.lang.ClassLoader
the system class loader.
static void
Deprecated. The new jsx3.lang.Class framework does not use this constant for instantiating objects.
static jsx3.EVT
Deprecated. Static access to the event object is deprecated as it is not cross-platform. Access to the current event object, where available, is granted via a method parameter or model event context variable.
static String
Deprecated.
static void
Deprecated. The new jsx3.lang.Class framework does not use this constant for instantiating objects.
static jsx3.gui.Event
static String
Deprecated.
static String
Deprecated.
Method Summary
static void
$A(a : Array | Object)
Injects class jsx3.$Array into array instance a.
static void
$F(f : Function)
Injects class jsx3.$Function into function instance f.
static void
$H(o : Object | Array)
Injects class jsx3.$Hash into object instance o.
static void
$O(o : Object)
Injects class jsx3.$Object into object instance o.
static void
$S(s : String)
Injects class jsx3.$String into string instance s.
static Function
$Y(f : Function)
Wraps an asynchronous method.
static Function
$Z(strMethod : String | Function, objThis : Object | jsx3.$AsyncRV)
Returns an asynchronous wrapper of a synchronous method.
static jsx3.app.Model
GO(strIdName : String, strNS : String | jsx3.app.Server)
global call to get a handle to a specific JSX GUI Object; NOTE: This is a significant modification used to support multi-instance servers.
static void
doDefine(strClassName : String, anonymousFunction : String)
Deprecated. create classes using jsx3.Class
static void
doImplement(subClass : String, superClass : String)
Deprecated. create classes using jsx3.Class
static void
doInherit(subClass : String, superClass : String, bImplement : boolean)
Deprecated. create classes using jsx3.Class
static void
doMixin(objInstance : Object, strClassName : String)
Deprecated. use jsx3.Class.mixin()
static void
eval(strScript : String, objContext : Object)
Evaluate a string of code with a particular local variable stack context.
static Object
getClassConstants(strClassName : String)
Deprecated. use jsx3.lang.Class
static String
getClassMethods(strClassName : String)
Deprecated. use jsx3.lang.Class
static String
getEnv(strKey : String)
static String
getInstanceMethods(strClassName : String)
Deprecated. use jsx3.lang.Class
static jsx3.app.Cache
Returns the global JSX XML/XSL cache.
static void
Returns the version of General Interface.
static void
log(strMessage : String)
Sends a message to the logging system.
static void
out(strErrorNumber : String, strMessage : String, PRIORITY : int, bTrace : boolean)
Deprecated. use jsx3.log() or the jsx3.util.Logger interface
static void
require(strClass : String...)
Ensures that one or more classes is available before this method returns.
static String
Returns a URI resolved against the default URI resolver, URIResolver.DEFAULT.
static void
sleep(objFunction : Function, strId : String, objThis : Object, bClobber : boolean)
A replacement for peppering code with window.setTimeout(fnct, 0) statements.
Field Detail

ABSOLUTEPATH

static String ABSOLUTEPATH
Deprecated. Use jsx3.getEnv("jsxabspath").
Absolute path (the path on the server (file or http) from the accessible root to the directory containing the JSX system folder. Specifies a directory (ie it's empty or ends with a "/").

ADDINSPATH

static String ADDINSPATH
location for addin resources.

APPPATH

static String APPPATH
Deprecated. Use jsx3.getEnv("jsxhomepath").
Path for application resources (the prefix that precedes JSXAPPS). Specifies a directory (ie it's empty or ends with a "/").

CACHE

static jsx3.app.Cache CACHE
Deprecated. Use getSharedCache() instead.
The jsx3.app.Cache instance used by the JSX system to store XML and XSL documents.

CLASS_LOADER

static jsx3.lang.ClassLoader CLASS_LOADER
the system class loader.

DESERIALIZE

static ? DESERIALIZE
Deprecated. The new jsx3.lang.Class framework does not use this constant for instantiating objects.

EVENT

static jsx3.EVT EVENT
Deprecated. Static access to the event object is deprecated as it is not cross-platform. Access to the current event object, where available, is granted via a method parameter or model event context variable.
wrapped static access to the current JavaScript event

HTTPREGKEY

static String HTTPREGKEY
Deprecated.
Default ActiveX HTTP object key.

INITIALIZE

static ? INITIALIZE
Deprecated. The new jsx3.lang.Class framework does not use this constant for instantiating objects.

STARTUP_EVENT

static jsx3.gui.Event STARTUP_EVENT

XMLREGKEY

static String XMLREGKEY
Deprecated.
Default ActiveX XML object key.

XSLREGKEY

static String XSLREGKEY
Deprecated.
Default ActiveX XSL object key.
Method Detail

$A

static void $A(a : Array | Object)
Injects class jsx3.$Array into array instance a.

Parameters:

a

Since:

3.7

$F

static void $F(f : Function)
Injects class jsx3.$Function into function instance f.

Parameters:

f

Since:

3.7

$H

static void $H(o : Object | Array)
Injects class jsx3.$Hash into object instance o. If o is an array, it is first converted into an object by setting a property equal to 1 for each item in the array.

Parameters:

o

Since:

3.7

$O

static void $O(o : Object)
Injects class jsx3.$Object into object instance o.

Parameters:

o

Since:

3.7

$S

static void $S(s : String)
Injects class jsx3.$String into string instance s.

Parameters:

s

Since:

3.7

$Y

static Function $Y(f : Function)
Wraps an asynchronous method. An asynchronous method follows a very strict contract. It can be called with any number of parameters but the wrapped method sees only a single parameter, an instance of jsx3.$AsyncCB. The wrapped method must call done() on this method parameter, either synchronously or asynchronously. The done() method takes a single parameter, which is the return value of the method.

The wrapped method should not itself return anything. The only exception to this is that the method may return and instance of jsx3.$AsyncRV. In this case, the method will return when and with the same return value as the returned instance of jsx3.$AsyncRV.

Client code that calls the asynchronous method will see a synchronous return value of type jsx3.$AsyncRV. Client code should use the when() method of this return value to continue execution when the asynchronous method has completed. Or this return value may be used in conjuction with other asynchronous methods (such as by passing is as a parameter to an asynchronous method).

Another feature of asynchronous methods is that you can pass instances of jsx3.$AsyncRV as parameters to the method and the method is only invoked once all of those parameters have returned. The parameters that the wrapped method sees are automatically converted into the return values of the jsx3.$AsyncRV instances.

Parameters:

fthe function to wrap.

Returns:

the wrapped function.  

Since:

3.7

See Also:


$Z

static Function $Z(strMethod : String | Function, objThis : Object | jsx3.$AsyncRV)
Returns an asynchronous wrapper of a synchronous method. The returned method is method strMethod bound to object objThis. objThis is optional and may be an object or an instance of jsx3.$AsyncRV. If the latter, then the wrapped method is only called on the return value of objThis after objThis returns.

The wrapper takes the same parameters as the wrapped method. However, instead of returning the return value of the wrapped method, it returns an instance of jsx3.$AsyncRV.

The returned method may be passed parameters that are actually instances of jsx3.$AsyncRV. In this case, the wrapped method is only actually called when all the parameters have returned.

Parameters:

strMethodthe function to wrap or the name of a method of objThis to wrap.
objThisoptionally, the object to which to bind the wrapper.

Returns:

the wrapper function. 

Since:

3.7

GO

static jsx3.app.Model GO(strIdName : String, strNS : String | jsx3.app.Server)
global call to get a handle to a specific JSX GUI Object; NOTE: This is a significant modification used to support multi-instance servers. It is equivalently the same as calling 'getJO' in all builds prior to 3.0; returns null if object cannot be found. The specific app (a jsx3.app.Server instance) can also be queried for objects using its own DOM APIs.

Parameters:

strIdNameJSX 'id' or 'name' property for the object to get a handle to
strNSnamespace for the server to get the object from; when a 'name' is passed as @strNameId (as opposed to the object's 'id'), this allows the global JSX controller to more-quickly find the server that owns the given object. As this parameter is optional, the JSX controller will try to locate the named object by iterating through all server instances running in the browser in load order if no namespace is passed. When an 'id' is passed, the namespaces is not required as it explicitly contains this namespace.

Returns:

handle to given JSX GUI object or null if none found 

doDefine

static void doDefine(strClassName : String, anonymousFunction : String)
Deprecated. create classes using jsx3.Class
Registers all prototype functions and properties, contained by the inner function @anonymousFunction; used by jsx3.Object

Parameters:

strClassNamenamed class containing the anonymous function to call
anonymousFunctioninner function containing named prototypes to bind

See Also:


doImplement

static void doImplement(subClass : String, superClass : String)
Deprecated. create classes using jsx3.Class
transfers prototype methods from one class to another

Parameters:

subClassnamed subclass to transfer prototypes to
superClassnamed superclass to transfer prototypes from

Returns:

the eval value of the script 

See Also:


doInherit

static void doInherit(subClass : String, superClass : String, bImplement : boolean)
Deprecated. create classes using jsx3.Class
transfers prototype methods from one class to another; establishes @superClass as the super for @subClass

Parameters:

subClassnamed subclass to transfer prototypes to
superClassnamed superclass to transfer prototypes from
bImplementif true, @superClass is an interface

Returns:

the eval value of the script 

See Also:


doMixin

static void doMixin(objInstance : Object, strClassName : String)
Deprecated. use jsx3.Class.mixin()
transfer the methods of a class to a object instance

Parameters:

objInstanceany JavaScript object
strClassNamethe name of a class

See Also:


eval

static void eval(strScript : String, objContext : Object)
Evaluate a string of code with a particular local variable stack context.

Parameters:

strScriptthe code to execute
objContexta map containing the local variable stack context

Returns:

the eval value of the script  

getClassConstants

static Object getClassConstants(strClassName : String)
Deprecated. use jsx3.lang.Class
Returns a JavaScript array of all named constants for this class; these names (strings) can then be used by the developer to lookup/evaluate/modify applicable constants; To derive the value for the first named constant for the jsx3.gui.Block class, a method such as the following would work: var myFirstConstantValue = eval(jsx3.getClassConstants("jsx3.gui.Block")[0]); NOTE: passing an invalid class name results in a null value being returned. If no constants exist for the given class, an empty array will be returned

Parameters:

strClassNamename of the class to get the constants for. For example: jsx3.gui.Block, jsx3.gui.Select, etc.

Returns:

JavaScript array 

See Also:


getClassMethods

static String getClassMethods(strClassName : String)
Deprecated. use jsx3.lang.Class
Returns a new-line-delimited (e.g., \n) list of all instance methods for the particular class

Parameters:

strClassNamename of the class to get the constants for. For example: jsx3.gui.Block, jsx3.gui.Select, etc.

Returns:

 

See Also:


getEnv

static String getEnv(strKey : String)

Parameters:

strKey

Returns:

 

getInstanceMethods

static String getInstanceMethods(strClassName : String)
Deprecated. use jsx3.lang.Class
Returns a new-line-delimited (e.g., \n) list of all instance methods for the particular class

Parameters:

strClassNamename of the class to get the constants for. For example: jsx3.gui.Block, jsx3.gui.Select, etc.

Returns:

 

See Also:


getSharedCache

static jsx3.app.Cache getSharedCache()
Returns the global JSX XML/XSL cache. This cache is shared by all applications in the JSX runtime. Every server cache instance consults this cache when getDocument() is called on the server cache with a cache id that does not correspond to a document in the server cache.

Returns:

 

getVersion

static void getVersion()
Returns the version of General Interface.

log

static void log(strMessage : String)
Sends a message to the logging system. This method is an alias for jsx3.util.Logger.GLOBAL.info().

Since this method is defined before the logging system, any messages passed to this method before the logging system is defined are cached and sent with the first message passed after the logging system is defined.

Parameters:

strMessagethe message to send to the logging system.

See Also:


out

static void out(strErrorNumber : String, strMessage : String, PRIORITY : int, bTrace : boolean)
Deprecated. use jsx3.log() or the jsx3.util.Logger interface
Alias for jsx3.util.Logger.doLog() (formerly jsx3.Error.doLog()).

Parameters:

strErrorNumberarbitrary identifier passed by the calling function to track the specific location of the error
strMessagemessage to describe the error
PRIORITYone of 1, 2 or 3, with 1 being most serious (red..orange..yellow)
bTracetrue if null; if true, the stack trace is printed, displaying the order of the call stack

See Also:


require

static void require(strClass : String...)
Ensures that one or more classes is available before this method returns. Any class that fails to load will throw an error. Only classes that can be found by the system class loader may be loaded in this manner.

Parameters:

strClassthe fully-qualified names of the classes to load.

Since:

3.2

resolveURI

static String resolveURI(strURI : String | jsx3.net.URI)
Returns a URI resolved against the default URI resolver, URIResolver.DEFAULT.

Parameters:

strURIthe URI to resolve.

Returns:

 

See Also:


sleep

static void sleep(objFunction : Function, strId : String, objThis : Object, bClobber : boolean)
A replacement for peppering code with window.setTimeout(fnct, 0) statements. This method places all jobs in a queue. Each job gets its own stack.

Parameters:

objFunctionan anonymous function to call after a timeout.
strIdthe id of this job. If this parameter is not null and a job already exists in the queue with this id, then this job is not added to the queue.
objThisif provided, this object is the "this" context for the anonymous function objFunction when it is called.
bClobberif true and a job already exists, this new job clobbers the old job.

Since:

3.2

jsx3

class $Array

Object
->Array
  ->jsx3.$Array

class $Array
extends Array
Useful extensions to the JavaScript Array class.

Since:

3.7

Fields Inherited From Array
length
Method Summary
void
addAll(a : Array)
Appends the contents of a to this array.
boolean
Returns true if o is in this array.
void
each(fct : Function)
Calls fct for each element in this array.
jsx3.$Array
filter(fct : Function)
Creates a new array with the filtered contents of this array.
Object
find(fct : Function)
Returns the first element in this array for which fct returns true when passed the element as the sole parameter.
int
Returns the first index of o in this array.
jsx3.$Array
map(fct : Function)
Creates a new array using the mapped values of each element in this array.
Object
remove(o : Object)
Removes the first occurrence of o in this array.
jsx3.$Array
Returns a list containing only the unique elements in this list.
Methods Inherited From Array
clone, concat, contentsEqual, join, lastIndexOf, pop, push, pushAll, reverse, shift, slice, sort, splice, toString, unshift
Method Detail

addAll

void addAll(a : Array)
Appends the contents of a to this array.

Parameters:

a

contains

boolean contains(o : Object)
Returns true if o is in this array. This method uses strict equality for comparing objects (===).

Parameters:

o

Returns:

 

Overrides:


each

void each(fct : Function)
Calls fct for each element in this array. fct is passed each element as the sole parameter.

Parameters:

fct

filter

jsx3.$Array filter(fct : Function)
Creates a new array with the filtered contents of this array. fct is called for each element in this array and the element is passed as the sole argument. The new array is constructed with only the elements of this array for which fct returns true.

Parameters:

fct

Returns:

 

Overrides:


find

Object find(fct : Function)
Returns the first element in this array for which fct returns true when passed the element as the sole parameter.

Parameters:

fct

Returns:

 

indexOf

int indexOf(o : Object)
Returns the first index of o in this array. This method uses strict equality for comparing objects (===).

Parameters:

o

Returns:

 

Overrides:


map

jsx3.$Array map(fct : Function)
Creates a new array using the mapped values of each element in this array. fct is called for each element in this array and the element is passed as the sole argument. The new array is constructed with the return values of each call to fct. sole parameter.

Parameters:

fct

Returns:

 

Overrides:


remove

Object remove(o : Object)
Removes the first occurrence of o in this array. This method uses strict equality for comparing objects (===).

Parameters:

o

Returns:

the removed object or undefined if o is not in this array.  

Overrides:


unique

jsx3.$Array unique()
Returns a list containing only the unique elements in this list.

Returns:

 

jsx3

class $AsyncCB

Object
->jsx3.$AsyncCB

class $AsyncCB
extends Object
The callback object passed as the single argument to an asynchronous method.

Since:

3.7

See Also:


Method Summary
Array<Object>
Returns the arguments that were passed to the asynchronous method wrapper.
void
done(rv : Object)
Signals the callback object that the asynchronous method is done and passes the asynchronous return value.
Methods Inherited From Object
toString
Method Detail

args

Array<Object> args()
Returns the arguments that were passed to the asynchronous method wrapper.

Returns:

 

done

void done(rv : Object)
Signals the callback object that the asynchronous method is done and passes the asynchronous return value.

Parameters:

rvthe return value.

jsx3

class $AsyncRV

Object
->jsx3.$AsyncRV

class $AsyncRV
extends Object
The return value from an asynchronous method.

Since:

3.7

See Also:


Method Summary
jsx3.$AsyncRV
and(rv : jsx3.$AsyncRV...)
Creates and returns an asynchronous return value that completes when this and rv have completed.
jsx3.$AsyncRV
or(rv : jsx3.$AsyncRV...)
Creates and returns an asynchronous return value that completes when this or rv have completed.
Object
rv()
Returns the return value from the asynchronous method.
void
when(cb : Function | jsx3.$AsyncCB, rv : Object)
Registers code to be called when the asynchronous method completes.
Methods Inherited From Object
toString
Method Detail

and

jsx3.$AsyncRV and(rv : jsx3.$AsyncRV...)
Creates and returns an asynchronous return value that completes when this and rv have completed.

Parameters:

rv

Returns:

 

or

jsx3.$AsyncRV or(rv : jsx3.$AsyncRV...)
Creates and returns an asynchronous return value that completes when this or rv have completed.

Parameters:

rv

Returns:

 

rv

Object rv()
Returns the return value from the asynchronous method.

Throws:

{Error}if called before done() is called on corresponding callback object.

Returns:

 

when

void when(cb : Function | jsx3.$AsyncCB, rv : Object)
Registers code to be called when the asynchronous method completes.

If argument cb is a function, then that function will be called when the asynchronous method completes. This function will be called synchronously is the function has already completed. The asynchronous method return value will be passed as the only argument to the function.

If argument cb is an instance of jsx3.$AsyncCB, then its done() method will be called when the asynchronous method completes. The done method will be passed the rv argument it is is provided. Otherwise, it will be passed the return value of cb.

Parameters:

cb
rv

jsx3

class $Function

Object
->jsx3.$Function

class $Function
extends Object
Useful extensions to the JavaScript Function class.

Since:

3.7

Method Summary
jsx3.$Function
bind(thisObj : Object, argsArr : Array)
Returns a method that is this function applied to thisObj with arguments argsArr.
Methods Inherited From Object
toString
Method Detail

bind

jsx3.$Function bind(thisObj : Object, argsArr : Array)
Returns a method that is this function applied to thisObj with arguments argsArr.

Parameters:

thisObj
argsArr

Returns:

 

jsx3

class $Hash

Object
->jsx3.$Object
  ->jsx3.$Hash

class $Hash
extends jsx3.$Object
Useful extensions to the JavaScript Object class for emulating a hashtable.

Since:

3.7

Method Summary
void
each(fct : Function)
Iterates over all the key-value pairs of this hashtable.
jsx3.$Array
Returns the list of keys of this hashtable.
jsx3.$Array
Returns the list of values of this hashtable.
Methods Inherited From jsx3.$Object
clone, extend
Methods Inherited From Object
toString
Method Detail

each

void each(fct : Function)
Iterates over all the key-value pairs of this hashtable. fct is called for each pair; the pair key is the first parameter and the pair value is the second parameter.

Parameters:

fctfunction(key : String, value: Object} : void

keys

jsx3.$Array keys()
Returns the list of keys of this hashtable.

Returns:

 

values

jsx3.$Array values()
Returns the list of values of this hashtable.

Returns:

 

jsx3

class $Object

Object
->jsx3.$Object

Direct Known Subclasses:

jsx3.$Hash, jsx3.$String

class $Object
extends Object
Useful extensions to the JavaScript Object class.

Since:

3.7

Method Summary
jsx3.$Object
Creates a new objects with all the same properties as this object.
void
extend(o : Object)
Copies all properties of o into this object.
Methods Inherited From Object
toString
Method Detail

clone

jsx3.$Object clone()
Creates a new objects with all the same properties as this object.

Returns:

 

extend

void extend(o : Object)
Copies all properties of o into this object.

Parameters:

o

jsx3

class $String

Object
->jsx3.$Object
  ->jsx3.$String

class $String
extends jsx3.$Object
Useful extensions to the JavaScript String class.

Since:

3.7

Method Summary
boolean
Returns true if this string ends with string s.
jsx3.$String
Returns this string with all leading and trailing space removed.
Methods Inherited From jsx3.$Object
clone, extend
Methods Inherited From Object
toString
Method Detail

endsWith

boolean endsWith(s : String)
Returns true if this string ends with string s.

Parameters:

s

Returns:

 

trim

jsx3.$String trim()
Returns this string with all leading and trailing space removed.

Returns:

 

jsx3

interface Alerts

jsx3.Alerts

interface Alerts
Deprecated. Renamed to jsx3.gui.Alerts.

See Also:

jsx3.gui.Alerts

jsx3

class Block

jsx3.Block

class Block
Deprecated. Renamed to jsx3.gui.Block

See Also:

jsx3.gui.Block

jsx3

class BlockX

jsx3.BlockX

class BlockX
Deprecated. Renamed to jsx3.gui.BlockX. Most functionality of this class was moved into a new interface, jsx3.xml.Cacheable.

See Also:

jsx3.gui.BlockX, jsx3.xml.Cacheable

jsx3

class Boolean

jsx3.Boolean

class Boolean
Boolean class encapsulates GI's XML boolean values (0 and 1 rather than true and false).

Field Summary
static int
0
static int
1
Method Summary
static int
Returns jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.
Field Detail

FALSE

static final int FALSE
0

TRUE

static final int TRUE
1
Method Detail

valueOf

static int valueOf(v : Object)
Returns jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.

Parameters:

vboolean (or similar) that when evaluated via an 'if' would result in a true false; For example, null, 0 (numeric zero), and false all return jsx3.Boolean.FALSE

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

jsx3

class Button

jsx3.Button

class Button
Deprecated. Renamed to jsx3.gui.Button

See Also:

jsx3.gui.Button

jsx3

interface CDF

jsx3.CDF

interface CDF
Deprecated. Renamed to jsx3.xml.CDF

See Also:

jsx3.xml.CDF

jsx3

class Cache

jsx3.Cache

class Cache
Deprecated. Renamed to jsx3.app.Cache

See Also:

jsx3.app.Cache

jsx3

class CheckBox

jsx3.CheckBox

class CheckBox
Deprecated. Renamed to jsx3.gui.CheckBox

See Also:

jsx3.gui.CheckBox

jsx3

class Collection

jsx3.Collection

class Collection
Deprecated. Subsumed by jsx3.util.List.

See Also:

jsx3.util.List

jsx3

class Column

jsx3.Column

class Column
Deprecated. Renamed to jsx3.gui.Column

See Also:

jsx3.gui.Column

jsx3

class DOM

jsx3.DOM

class DOM
Deprecated. Renamed to jsx3.app.DOM

See Also:

jsx3.app.DOM

jsx3

class DatePicker

jsx3.DatePicker

class DatePicker
Deprecated. Renamed to jsx3.gui.DatePicker

See Also:

jsx3.gui.DatePicker

jsx3

class Dialog

jsx3.Dialog

class Dialog
Deprecated. Renamed to jsx3.gui.Dialog

See Also:

jsx3.gui.Dialog

jsx3

class Document

jsx3.Document

class Document
Deprecated. Renamed to jsx3.xml.Document

See Also:

jsx3.xml.Document

jsx3

class ERROR

jsx3.ERROR

class ERROR
Deprecated. Renamed to jsx3.util.Logger

See Also:

jsx3.util.Logger

jsx3

class EVT

Object
->jsx3.lang.Object
  ->jsx3.EVT

All Implemented Interfaces:

jsx3.util.EventDispatcher

class EVT
extends jsx3.lang.Object
Deprecated. Use class jsx3.gui.Event instead.
This class is the static event controller for the GI framework. It abstracts the browser-specific implementations of the event object while providing extensions of its own (i.e., drag/drop, event binding, etc).

See Also:

jsx3.gui.Event

Constructor Summary
void
init(e : ?)
Use this instance initializer for wrapped access to the current event object event at a later point in time.
Method Summary
boolean
Returns true if the alt key was pressed
boolean
Returns true if the backspace key was pressed
int
Returns integer designating the mouse button clicked/moused-down/moused-up; 1 (left), 2 (right), and as supported
void
cancels event bubbling for the event
void
cancels the key from firing by setting the keyCode to 0 (zero) for the event
void
cancels the returnValue for the event
int
Returns the clientX property for the event (where it occurred on-screen)
int
Returns the clientY property for the event (where it occurred on-screen)
boolean
Returns true if the ctrl key was pressed
boolean
Returns true if the delete key was pressed
boolean
Returns true if the down-arrow key was pressed
boolean
Returns true if the end key was pressed
boolean
Returns true if the enter key was pressed
boolean
Returns true if the escape key was pressed
Object
Returns handle to the native browser event object (window.event)
boolean
Returns true if the native event object is present (if an event of any type actualy occurred)
HTMLElement
Returns handle to the HTML element that was moused away from (onmouseout)
int
Returns the actual position in the browser from the left edge for where the event occurred;
int
Returns the actual position in the browser from the top edge for where the event occurred;
Object
handleEvent(strType : String, bReturn : boolean)
Deprecated. use jsx3.gui.Event.publish() instead
boolean
Returns true if the home key was pressed
boolean
Returns true if the insert key was pressed
int
Returns integer representing the key code of the key just pressed/keyed-down
boolean
Returns true if the left-arrow key was pressed
boolean
Returns true if the left-mouse-button was clicked
boolean
Returns true if the page-down key was pressed
boolean
Returns true if the page-up key was pressed
void
registerEvent(EVENTTYPE : String, strCode : String)
Deprecated. use jsx3.gui.Event.subscribe instead
boolean
Returns true if the right-arrow key was pressed
boolean
Returns true if the right-mouse-button was clicked
void
setKeyCode(intKeyCode : int)
sets/updates the keycode for the event
void
setReturn(RETURN : String)
sets string message to set on the returnValue for the event
boolean
Returns true if the shift key was pressed
boolean
Returns true if the space bar was pressed
HTMLElement
Returns handle to the HTML element acted upon (click, mousedown, etc)
boolean
Returns true if the tab key was pressed
HTMLElement
Returns handle to the HTML element that was moused over (onmouseover)
boolean
Returns true if the up-arrow key was pressed
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(e : ?)
Use this instance initializer for wrapped access to the current event object event at a later point in time.

Parameters:

e
Method Detail

altKey

boolean altKey()
Returns true if the alt key was pressed

Returns:

 

backspaceKey

boolean backspaceKey()
Returns true if the backspace key was pressed

Returns:

 

button

int button()
Returns integer designating the mouse button clicked/moused-down/moused-up; 1 (left), 2 (right), and as supported

Returns:

 

cancelBubble

void cancelBubble()
cancels event bubbling for the event

cancelKey

void cancelKey()
cancels the key from firing by setting the keyCode to 0 (zero) for the event

cancelReturn

void cancelReturn()
cancels the returnValue for the event

clientX

int clientX()
Returns the clientX property for the event (where it occurred on-screen)

Returns:

pixel position  

clientY

int clientY()
Returns the clientY property for the event (where it occurred on-screen)

Returns:

pixel position  

ctrlKey

boolean ctrlKey()
Returns true if the ctrl key was pressed

Returns:

 

deleteKey

boolean deleteKey()
Returns true if the delete key was pressed

Returns:

 

downArrow

boolean downArrow()
Returns true if the down-arrow key was pressed

Returns:

 

endKey

boolean endKey()
Returns true if the end key was pressed

Returns:

 

enterKey

boolean enterKey()
Returns true if the enter key was pressed

Returns:

 

escapeKey

boolean escapeKey()
Returns true if the escape key was pressed

Returns:

 

event

Object event()
Returns handle to the native browser event object (window.event)

Returns:

event  

exists

boolean exists()
Returns true if the native event object is present (if an event of any type actualy occurred)

Returns:

 

fromElement

HTMLElement fromElement()
Returns handle to the HTML element that was moused away from (onmouseout)

Returns:

HTML object  

getTrueX

int getTrueX()
Returns the actual position in the browser from the left edge for where the event occurred;

Returns:

pixel position  

getTrueY

int getTrueY()
Returns the actual position in the browser from the top edge for where the event occurred;

Returns:

pixel position  

handleEvent

Object handleEvent(strType : String, bReturn : boolean)
Deprecated. use jsx3.gui.Event.publish() instead
the JSXEVENT class maintains an object array indexed via the EVENTTYPE constant for the given event. When the event bubbles up the IE DOM, or when this function is called directly, the JScript code bound to the given event is exectued via the JScript 'eval()' function

Parameters:

strTypethe event type to handle
bReturn

Returns:

the result of the event eval, but only if parameter bReturn is true, otherwise no return statement 

homeKey

boolean homeKey()
Returns true if the home key was pressed

Returns:

 

insertKey

boolean insertKey()
Returns true if the insert key was pressed

Returns:

 

keyCode

int keyCode()
Returns integer representing the key code of the key just pressed/keyed-down

Returns:

keycode  

leftArrow

boolean leftArrow()
Returns true if the left-arrow key was pressed

Returns:

 

leftButton

boolean leftButton()
Returns true if the left-mouse-button was clicked

Returns:

 

pageDownKey

boolean pageDownKey()
Returns true if the page-down key was pressed

Returns:

 

pageUpKey

boolean pageUpKey()
Returns true if the page-up key was pressed

Returns:

 

registerEvent

void registerEvent(EVENTTYPE : String, strCode : String)
Deprecated. use jsx3.gui.Event.subscribe instead
typically called by a JSX GUI foundation class (such as the JSXMenu class). Allows the given class to be notified when a given event occurs. For example in the case of the JSXMenu class, it must be notified to hide any visible menu when the user mouses down in the document.

Parameters:

EVENTTYPEthe type of event to handle such as mousedown, mouseup, etc
strCodeJScript code (passed as string) that will be evaluated via the JScript eval() function when the given event fires. Note: it is important that the code contain a trailing semicolon ';', in case a subsequent function binds its own callback code

See Also:


rightArrow

boolean rightArrow()
Returns true if the right-arrow key was pressed

Returns:

 

rightButton

boolean rightButton()
Returns true if the right-mouse-button was clicked

Returns:

 

setKeyCode

void setKeyCode(intKeyCode : int)
sets/updates the keycode for the event

Parameters:

intKeyCodekeycode

setReturn

void setReturn(RETURN : String)
sets string message to set on the returnValue for the event

Parameters:

RETURNstring message to set on the returnValue for the event

shiftKey

boolean shiftKey()
Returns true if the shift key was pressed

Returns:

 

spaceKey

boolean spaceKey()
Returns true if the space bar was pressed

Returns:

 

srcElement

HTMLElement srcElement()
Returns handle to the HTML element acted upon (click, mousedown, etc)

Returns:

HTML object  

tabKey

boolean tabKey()
Returns true if the tab key was pressed

Returns:

 

toElement

HTMLElement toElement()
Returns handle to the HTML element that was moused over (onmouseover)

Returns:

HTML object  

upArrow

boolean upArrow()
Returns true if the up-arrow key was pressed

Returns:

 

jsx3

class Entity

jsx3.Entity

class Entity
Deprecated. Renamed to jsx3.xml.Entity

See Also:

jsx3.xml.Entity

jsx3

interface Event

jsx3.Event

interface Event
Deprecated. Renamed to jsx3.gui.Interactive

See Also:

jsx3.gui.Interactive

jsx3

interface EventDispatcher

jsx3.EventDispatcher

interface EventDispatcher
Deprecated. Renamed to jsx3.util.EventDispatcher

See Also:

jsx3.util.EventDispatcher

jsx3

interface Form

jsx3.Form

interface Form
Deprecated. Renamed to jsx3.gui.Form

See Also:

jsx3.gui.Form

jsx3

class Grid

jsx3.Grid

class Grid
Deprecated. Renamed to jsx3.gui.Grid

See Also:

jsx3.gui.Grid

jsx3

class Heavyweight

jsx3.Heavyweight

class Heavyweight
Deprecated. Renamed to jsx3.gui.Heavyweight

See Also:

jsx3.gui.Heavyweight

jsx3

class HttpForm

jsx3.HttpForm

class HttpForm
Deprecated. Renamed to jsx3.net.Form

See Also:

jsx3.net.Form

jsx3

class HttpRequest

jsx3.HttpRequest

class HttpRequest
Deprecated. Renamed to jsx3.net.Request

See Also:

jsx3.net.Request

jsx3

class LayoutGrid

jsx3.LayoutGrid

class LayoutGrid
Deprecated. Renamed to jsx3.gui.LayoutGrid

See Also:

jsx3.gui.LayoutGrid

jsx3

class List

jsx3.List

class List
Deprecated. Renamed to jsx3.gui.List

See Also:

jsx3.gui.List

jsx3

class Menu

jsx3.Menu

class Menu
Deprecated. Renamed to jsx3.gui.Menu

See Also:

jsx3.gui.Menu

jsx3

class Model

jsx3.Model

class Model
Deprecated. Renamed to jsx3.app.Model

See Also:

jsx3.app.Model

jsx3

class RadioButton

jsx3.RadioButton

class RadioButton
Deprecated. Renamed to jsx3.gui.RadioButton

See Also:

jsx3.gui.RadioButton

jsx3

class Select

jsx3.Select

class Select
Deprecated. Renamed to jsx3.gui.Select

See Also:

jsx3.gui.Select

jsx3

class Server

jsx3.Server

class Server
Deprecated. Renamed to jsx3.app.Server

See Also:

jsx3.app.Server

jsx3

class Service

jsx3.Service

class Service
Deprecated. Renamed to jsx3.net.Service

See Also:

jsx3.net.Service

jsx3

class Settings

jsx3.Settings

class Settings
Deprecated. Renamed to jsx3.app.Settings

See Also:

jsx3.app.Settings

jsx3

class Slider

jsx3.Slider

class Slider
Deprecated. Renamed to jsx3.gui.Slider

See Also:

jsx3.gui.Slider

jsx3

class Splitter

jsx3.Splitter

class Splitter
Deprecated. Renamed to jsx3.gui.Splitter

See Also:

jsx3.gui.Splitter

jsx3

class Stack

jsx3.Stack

class Stack
Deprecated. Renamed to jsx3.gui.Stack

See Also:

jsx3.gui.Stack

jsx3

class StackGroup

jsx3.StackGroup

class StackGroup
Deprecated. Renamed to jsx3.gui.StackGroup

See Also:

jsx3.gui.StackGroup

jsx3

class Tab

jsx3.Tab

class Tab
Deprecated. Renamed to jsx3.gui.Tab

See Also:

jsx3.gui.Tab

jsx3

class TabbedPane

jsx3.TabbedPane

class TabbedPane
Deprecated. Renamed to jsx3.gui.TabbedPane

See Also:

jsx3.gui.TabbedPane

jsx3

class TextBox

jsx3.TextBox

class TextBox
Deprecated. Renamed to jsx3.gui.TextBox

See Also:

jsx3.gui.TextBox

jsx3

class ToolbarButton

jsx3.ToolbarButton

class ToolbarButton
Deprecated. Renamed to jsx3.gui.ToolbarButton

See Also:

jsx3.gui.ToolbarButton

jsx3

class Tree

jsx3.Tree

class Tree
Deprecated. Renamed to jsx3.gui.Tree

See Also:

jsx3.gui.Tree

jsx3

class UserSettings

jsx3.UserSettings

class UserSettings
Deprecated. Renamed to jsx3.app.UserSettings

See Also:

jsx3.app.UserSettings

jsx3

class WindowBar

jsx3.WindowBar

class WindowBar
Deprecated. Renamed to jsx3.gui.WindowBar

See Also:

jsx3.gui.WindowBar

package jsx3.amp

The General Interface Asynchronous Modular Platform (AMP). Classes in this package are only available to applications that enable the AMP add-in.

Since:

3.7

Class Summary
jsx3.amp.Bindable
jsx3.amp.Engine
An AMP engine.
jsx3.amp.Ext
An AMP extension.
jsx3.amp.ExtPoint
An AMP extension point.
jsx3.amp.ExtProc
An extension processor utility class.
jsx3.amp.PlugIn
An AMP plug-in.
jsx3.amp.Resource
An AMP plug-in resource, such as a JavaScript file or XML file.
jsx3.amp.XML
An XML wrapper that can be backed either by a real XML node or by a nested object structure.
Field Summary
static String
The name of the plug-ins registration file.
static String
The path where application plug-ins should reside.
static String
The name of a plug-in descriptor file.
static String
The plug-in definition XML namespace URI.
Field Detail

DESCRIPTOR

static String DESCRIPTOR
The name of the plug-ins registration file.

DIR

static String DIR
The path where application plug-ins should reside.

METAFILE

static String METAFILE
The name of a plug-in descriptor file.

NS

static String NS
The plug-in definition XML namespace URI.

jsx3.amp

interface Bindable

jsx3.amp.Bindable

All Known Implementing Classes:

jsx3.amp.PlugIn

interface Bindable
No description provided.

Method Summary
void
addBindableProp(key : String, expression : String)
Adds a bindable property to this object.
jsx3.$Array<String>
Returns the list of bindable properties of this object.
void
setBindableProp(key : String, newValue : Object)
Sets the current calculated value of a bindable property of this object.
void
Causes a bindable property of this object to be recalculated.
void
updateBindableOn(key : String, publisher : jsx3.util.EventDispatcher, subject : String)
Causes a bindable property to be updated when publisher publishes an event with subject subject.
Method Detail

addBindableProp

void addBindableProp(key : String, expression : String)
Adds a bindable property to this object.

Parameters:

keythe property name.
expressionthe binding expression.

getBindableProps

jsx3.$Array<String> getBindableProps()
Returns the list of bindable properties of this object.

Returns:

 

setBindableProp

void setBindableProp(key : String, newValue : Object)
Sets the current calculated value of a bindable property of this object. If the new value does not match the old value, an event is published. The schema of the event is {subject: propName, oldValue: previousValue, value: newValue}.

Parameters:

keythe property name.
newValuethe next calculated value.

updateBindable

void updateBindable(key : String)
Causes a bindable property of this object to be recalculated. The property is set to the value of the binding expression, evaluated in the context of this object. If the property value has changed then this object will publish an event with subject key.

Parameters:

keythe property to recalculate.

updateBindableOn

void updateBindableOn(key : String, publisher : jsx3.util.EventDispatcher, subject : String)
Causes a bindable property to be updated when publisher publishes an event with subject subject.

Parameters:

keythe property to update.
publisherthe object to which to subscribe.
subjectthe event subject to which to subscribe.

jsx3.amp

class Engine

Object
->jsx3.lang.Object
  ->jsx3.amp.Engine

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Engine
extends jsx3.lang.Object
An AMP engine. There is one engine instance per application that loads the AMP add-in.

See Also:


Field Summary
static String
Event subject published when an error prevents the engine from loading.
static String
Event subject published when an engine finishes loading.
static String
Event subject published when progress is made loading an engine.
static String
Event subject published when a plug-in is registered.
Method Summary
void
deregister(strId : String)
Deregisters a plug-in from this engine.
static jsx3.amp.Engine
getEngine(objServer : jsx3.app.Server)
Returns the engine for a given application.
jsx3.amp.ExtPoint
getExtPoint(strId : String)
Returns a registered extension point by ID.
jsx3.$Array<jsx3.amp.Ext>
getExts(strId : String)
Returns the extensions registered for a given extension point ID.
jsx3.amp.PlugIn
getPlugIn(strId : String)
Returns a registered plug-in by ID.
jsx3.$Array<jsx3.amp.PlugIn>
Returns all registered plug-ins.
jsx3.app.Server
Returns the application associated with this engine.
boolean
Returns true if all of the AMP and project plug-ins have been registered.
jsx3.$AsyncRV
register(strId : String, strPath : String, objXML : jsx3.xml.Entity)
Registers a plug-in manually at runtime.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

ERROR

static String ERROR
Event subject published when an error prevents the engine from loading.

LOAD

static String LOAD
Event subject published when an engine finishes loading.

PROGRESS

static String PROGRESS
Event subject published when progress is made loading an engine. pct and done fields may be defined.

REGISTER

static String REGISTER
Event subject published when a plug-in is registered.
Method Detail

deregister

void deregister(strId : String)
Deregisters a plug-in from this engine. Note that garbage collection may be incomplete if application code references the plug-in or any of its extension points or extensions. Also, this method does not unload any JavaScript, CSS, or XML resources from the browser page or the AMP application. Unexpecting things may happen if this method is called while the plug-in is still loading.

Parameters:

strIdthe ID of the plug-in to deregister.

getEngine

static jsx3.amp.Engine getEngine(objServer : jsx3.app.Server)
Returns the engine for a given application.

Parameters:

objServer

Returns:

 

getExtPoint

jsx3.amp.ExtPoint getExtPoint(strId : String)
Returns a registered extension point by ID.

Parameters:

strIdthe ID of the extension point.

Returns:

 

getExts

jsx3.$Array<jsx3.amp.Ext> getExts(strId : String)
Returns the extensions registered for a given extension point ID.

Parameters:

strIdthe ID of the extension point.

Returns:

 

getPlugIn

jsx3.amp.PlugIn getPlugIn(strId : String)
Returns a registered plug-in by ID.

Parameters:

strId

Returns:

 

getPlugIns

jsx3.$Array<jsx3.amp.PlugIn> getPlugIns()
Returns all registered plug-ins.

Returns:

 

getServer

jsx3.app.Server getServer()
Returns the application associated with this engine.

Returns:

 

isLoaded

boolean isLoaded()
Returns true if all of the AMP and project plug-ins have been registered.

Returns:

 

register

asynchronous jsx3.$AsyncRV register(strId : String, strPath : String, objXML : jsx3.xml.Entity)
Registers a plug-in manually at runtime. Only plug-ins not referenced in the main plugins.xml file should be loaded in this way.

Parameters:

strIdthe plug-in ID.
strPaththe relative path from the application directory to the directory containing the plug-in directory.
objXMLthe optional XML declaration of the plug-in. Providing this parameter prevents this method from requesting the plug-in descriptor file.

Returns:

 

jsx3.amp

class Ext

Object
->jsx3.lang.Object
  ->jsx3.amp.Ext

class Ext
extends jsx3.lang.Object
An AMP extension.

Method Summary
jsx3.$Array<jsx3.amp.XML>
Returns the list of XML elements declared in the body of the extension declaration.
jsx3.amp.Engine
Returns the engine owning the plug-in owning this extension.
String
Returns the full ID of this extension, which is unique among all extensions in the AMP engine.
String
Returns the local ID of this extension, which is defined by the id attribute of the XML extension declaration.
String
Returns the name of this extension, which is defined by the name attribute of the XML extension declaration.
jsx3.amp.PlugIn
Returns the plug-in declaring this extension.
jsx3.amp.ExtPoint
Returns the extension point to which this extension is registered.
String
Returns the ID of the extension point this this extension extends.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

getData

jsx3.$Array<jsx3.amp.XML> getData()
Returns the list of XML elements declared in the body of the extension declaration.

Returns:

 

getEngine

jsx3.amp.Engine getEngine()
Returns the engine owning the plug-in owning this extension.

Returns:

 

getId

String getId()
Returns the full ID of this extension, which is unique among all extensions in the AMP engine.

Returns:

 

getLocalId

String getLocalId()
Returns the local ID of this extension, which is defined by the id attribute of the XML extension declaration.

Returns:

 

getName

String getName()
Returns the name of this extension, which is defined by the name attribute of the XML extension declaration.

Returns:

 

getPlugIn

jsx3.amp.PlugIn getPlugIn()
Returns the plug-in declaring this extension.

Returns:

 

getPoint

jsx3.amp.ExtPoint getPoint()
Returns the extension point to which this extension is registered.

Returns:

 

getPointId

String getPointId()
Returns the ID of the extension point this this extension extends. This is equal to the point attribute of the XML extension declaration.

Returns:

 

jsx3.amp

class ExtPoint

Object
->jsx3.lang.Object
  ->jsx3.amp.ExtPoint

All Implemented Interfaces:

jsx3.util.EventDispatcher

class ExtPoint
extends jsx3.lang.Object
An AMP extension point.

Field Summary
static String
An event published by an extension point when it is extended by a new extension.
Method Summary
jsx3.amp.Engine
Returns the engine owning the plug-in owning this extension point.
jsx3.$Array<jsx3.amp.Ext>
Returns the list of extensions registered with this extension point.
String
Returns the full ID of this extension, which is unique among all extension points in the AMP engine.
String
Returns the local ID of this extension point, which is defined by the id attribute of the XML extension point declaration.
String
Returns the name of this extension point, which is defined by the name attribute of the XML extension point declaration.
jsx3.amp.PlugIn
Returns the plug-in declaring this extension point.
void
This method is called (after this extension point is instantiated) any time extensions are registered for this point.
jsx3.$Array<Object>
processExts(objProcessor : jsx3.amp.ExtProc | Function, arrExt : Array<jsx3.amp.Ext>)
Processes each extension of this extension point using the visitor pattern.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

EXTENDED

static String EXTENDED
An event published by an extension point when it is extended by a new extension.
Method Detail

getEngine

jsx3.amp.Engine getEngine()
Returns the engine owning the plug-in owning this extension point.

Returns:

 

getExts

jsx3.$Array<jsx3.amp.Ext> getExts()
Returns the list of extensions registered with this extension point.

Returns:

 

getId

String getId()
Returns the full ID of this extension, which is unique among all extension points in the AMP engine.

Returns:

 

getLocalId

String getLocalId()
Returns the local ID of this extension point, which is defined by the id attribute of the XML extension point declaration.

Returns:

 

getName

String getName()
Returns the name of this extension point, which is defined by the name attribute of the XML extension point declaration.

Returns:

 

getPlugIn

jsx3.amp.PlugIn getPlugIn()
Returns the plug-in declaring this extension point.

Returns:

 

onExtension

void onExtension(arrExts : jsx3.$Array<jsx3.amp.Ext>)
This method is called (after this extension point is instantiated) any time extensions are registered for this point. Subclasses may override this method to perform custom functionality but should call jsxsuper().

Parameters:

arrExts

processExts

jsx3.$Array<Object> processExts(objProcessor : jsx3.amp.ExtProc | Function, arrExt : Array<jsx3.amp.Ext>)
Processes each extension of this extension point using the visitor pattern.

Parameters:

objProcessorthe visitor. This argument may be null if the XML declaration of this extension point specifies a processor that can be constructed with the processor factory.
arrExtoptionally, a subset of the extensions of this extension point. Only these extensions will be processed if this parameter is not empty.

Returns:

the extensions to process, defaults to all the extensions of this extension point. 

See Also:

,

jsx3.amp

class ExtProc

Object
->jsx3.lang.Object
  ->jsx3.amp.ExtProc

class ExtProc
extends jsx3.lang.Object
An extension processor utility class.

See Also:

,

Field Summary
static jsx3.amp.ExtProc
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate.
static jsx3.amp.ExtProc
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate.
static jsx3.amp.ExtProc
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate.
Method Summary
static void
addProcessorFactory(strType : String, fctFactory : Function)
Registers a processor factory.
static void
getProcessor(strType : String, xml : jsx3.amp.XML)
Creates a processor object from a element.
static jsx3.amp.ExtProc
Creates a new extension processor that creates instances of a certain class.
static jsx3.$Array
process(arrExt : Array<jsx3.amp.Ext>, objVisitor : Function | Object)
Processes a list of extensions using the visitor pattern.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

EVAL

static jsx3.amp.ExtProc EVAL
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. The element should be named "eval" and the text body of the element is taken as the JavaScript to evaluate. The script is evaluated in the context of the extension object. So, for example, this.getPlugIn() grants access in the script to the plug-in defining the extension.

No value is returned from the extension processing. If the load attribute of the eval element is equal to "true" then the plug-in owning the extension is loaded before the script is evaluated. Therefore, the script may be evaluated either synchronously or asynchronously, but since there is no value returned from the processing, there is no way of knowing which one actually occurred.

RETURN

static jsx3.amp.ExtProc RETURN
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. The element should be named "eval" and the text body of the element is taken as the JavaScript to evaluate. The script is evaluated in the context of the extension object. So, for example, this.getPlugIn() grants access in the script to the plug-in defining the extension.

The value that the script evaluates to is returned from the extension processing.

RETURN_ASYNC

static jsx3.amp.ExtProc RETURN_ASYNC
Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. The element should be named "eval" and the text body of the element is taken as the JavaScript to evaluate. The script is evaluated in the context of the extension object. So, for example, this.getPlugIn() grants access in the script to the plug-in defining the extension.

The value returned from the extension processing is an asynchronous return value as defined in the contract for jsx3.$Y(). The return value may be notified either asynchronously or synchronously, depending on whether the load attribute of the eval element is equal to "true". If it is, then the plug-in owning the extension is loaded first and then the script is evaluated asynchronously. The asynchronous return value is notified of completion with the value that the script evaluates to.
Method Detail

addProcessorFactory

static void addProcessorFactory(strType : String, fctFactory : Function)
Registers a processor factory. A processor factory is the object responsible for creating a processor when a <processor> is found as a child of an <extension-point> element. Each processor element must declare a type attribute. The factory that has been registered with the matching type is used to create the processor. The method signature of the factory method is: function(xml : jsx3.amp.XML) : jsx3.amp.ExtProc where xml is the XML representation of the <processor> element.

Parameters:

strTypethe type of processor that the factory creates.
fctFactorythe factory function.

getProcessor

static void getProcessor(strType : String, xml : jsx3.amp.XML)
Creates a processor object from a <processor> element.

Parameters:

strTypethe type attribute of the <processor> element.
xmlthe <processor> element.

See Also:


newDescrProc

static jsx3.amp.ExtProc newDescrProc(objClass : String | jsx3.lang.Class | Function)
Creates a new extension processor that creates instances of a certain class. The only requirement of the class is that is have a two-argument constructor with the signature: function init(ext : jsx3.amp.Ext, xml : jsx3.amp.XML).

The processing visitor will create a new instance of objClass for each child element of each extension. If any child element defines a ext-class attribute, this is interpreted as the fully-qualified class name of a subclass of objClass. This class, if it is defined, will be used instead of objClass to process that particular child element.

Parameters:

objClassa class or constructor.

Returns:

 

process

static jsx3.$Array process(arrExt : Array<jsx3.amp.Ext>, objVisitor : Function | Object)
Processes a list of extensions using the visitor pattern. For each extension in arrExt, this method iterates over each child element of the extension declaration and invokes objVisitor for each element. At each iteration the visitor is passed as arguments the extension object and an XML object representing the child element.

Parameters:

arrExt
objVisitoran object that defines method process(ext : jsx3.amp.Ext, data: jsx3.amp.XML) : Object or the function itself.

Returns:

 

jsx3.amp

class PlugIn

Object
->jsx3.lang.Object
  ->jsx3.amp.PlugIn

All Implemented Interfaces:

jsx3.amp.Bindable, jsx3.net.URIResolver, jsx3.util.EventDispatcher

class PlugIn
extends jsx3.lang.Object
An AMP plug-in. A plug-in is a logical collection of application logic and resources. Plug-ins are loaded as needed and may contain extension points and extensions.

Field Summary
static String
Event subject published when an extension point of this plug-in has been extended.
static String
Event subject published when this plug-in has loaded completely.
Method Summary
jsx3.amp.Engine
Returns the engine of this plug-in.
jsx3.$Array<String>
Returns the list of event subjects that this plug-in declares to publish.
jsx3.amp.Ext
getExt(strId : String)
Returns an extension of this plug-in by its ID.
jsx3.amp.ExtPoint
getExtPoint(strId : String)
Returns an extension point of this plug-in by its ID.
jsx3.$Array<jsx3.amp.ExtPoint>
Returns the extension points of this plug-in.
jsx3.$Array<jsx3.amp.Ext>
Returns the extensions of this plug-in.
String
Returns the id attribute from the plug-in configuration element.
jsx3.util.Logger
Returns a logger for this plug-in.
String
Returns the name attribute from the plug-in configuration element.
jsx3.$Array<String>
Returns the list of plug-in IDs that this plug-in requires.
jsx3.amp.Resource
getResource(strId : String)
Returns a resource of this plug-in by its ID.
jsx3.$Array<jsx3.amp.Resource>
Returns the resources of this plug-in that are defined in the plug-in configuration data.
jsx3.app.Server
Returns the server of the engine of this plug-in.
String
Implements jsx3.net.URIResolver.
String
Returns the version attribute from the plug-in configuration element.
static void
Returns true if e is a binding expression.
boolean
Returns whether this is a global plug-in.
boolean
Returns true is all of the resources of this plug-in have loaded.
jsx3.$AsyncRV
Loads this plug-in asynchronously if it is not already loaded.
void
loadRsrcComponent(strRsrcId : String | jsx3.amp.Resource, objParent : jsx3.app.Model, bPaint : boolean)
Loads the contents of a plug-in resource as a GUI component.
void
onExtension(objExtPt : jsx3.amp.ExtPoint, arrExts : Array<jsx3.amp.Ext>)
Called (after this plug-in is instantiated) any time extensions are registered for an extension point of this plug-in.
void
Called when all the resources of this plug-in have loaded.
void
Calls when this plug-in is registered with its engine.
void
Called when the engine of this plug-in has completely registered all plug-ins.
void
regBindExpr(expression : String, handler : Function)
Registers a function to be called when the value of a binding expression changes.
jsx3.net.URI
relativizeURI(strURI : String | jsx3.net.URI, bRel : boolean)
Implements jsx3.net.URIResolver.
jsx3.net.URI
Implements jsx3.net.URIResolver.
void
Called after this plug-in is instantiated to provide the plug-in with its XML configuration data.
void
setEngine(objEngine : jsx3.amp.Engine)
Called after this plug-in is instantiated to provide the plug-in with the engine that created it.
void
setPath(strPath : String)
Called after this plug-in is instantiated to provide the plug-in with its path.
void
Called after this plug-in is instantiated to provide the plug-in with the resources defined in the configuration data.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.amp.Bindable
addBindableProp, getBindableProps, setBindableProp, updateBindable, updateBindableOn
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

EXTENDED

static String EXTENDED
Event subject published when an extension point of this plug-in has been extended.

READY

static String READY
Event subject published when this plug-in has loaded completely.
Method Detail

getEngine

jsx3.amp.Engine getEngine()
Returns the engine of this plug-in.

Returns:

 

getEvents

jsx3.$Array<String> getEvents()
Returns the list of event subjects that this plug-in declares to publish.

Returns:

 

getExt

jsx3.amp.Ext getExt(strId : String)
Returns an extension of this plug-in by its ID.

Parameters:

strIdthe local ID of the extension.

Returns:

 

getExtPoint

jsx3.amp.ExtPoint getExtPoint(strId : String)
Returns an extension point of this plug-in by its ID.

Parameters:

strIdthe local ID of the extension point.

Returns:

 

getExtPoints

jsx3.$Array<jsx3.amp.ExtPoint> getExtPoints()
Returns the extension points of this plug-in.

Returns:

 

getExts

jsx3.$Array<jsx3.amp.Ext> getExts()
Returns the extensions of this plug-in.

Returns:

 

getId

String getId()
Returns the id attribute from the plug-in configuration element.

Returns:

 

getLog

jsx3.util.Logger getLog()
Returns a logger for this plug-in.

Returns:

 

getName

String getName()
Returns the name attribute from the plug-in configuration element.

Returns:

 

getRequires

jsx3.$Array<String> getRequires()
Returns the list of plug-in IDs that this plug-in requires. These plug-ins must be loaded before this plug-in loads.

Returns:

 

getResource

jsx3.amp.Resource getResource(strId : String)
Returns a resource of this plug-in by its ID.

Parameters:

strId

Returns:

 

getResources

jsx3.$Array<jsx3.amp.Resource> getResources()
Returns the resources of this plug-in that are defined in the plug-in configuration data.

Returns:

 

getServer

jsx3.app.Server getServer()
Returns the server of the engine of this plug-in.

Returns:

 

getUriPrefix

String getUriPrefix()
Implements jsx3.net.URIResolver.

Returns:

 

Overrides:


getVersion

String getVersion()
Returns the version attribute from the plug-in configuration element.

Returns:

 

isBindExpr

static void isBindExpr(e : String)
Returns true if e is a binding expression. A binding expression starts with '{' and ends with '}'.

Parameters:

e

isGlobal

boolean isGlobal()
Returns whether this is a global plug-in. A global plug-in is only instantiated once for all of the applications that register it.

Returns:

 

isLoaded

boolean isLoaded()
Returns true is all of the resources of this plug-in have loaded.

Returns:

 

load

asynchronous jsx3.$AsyncRV load()
Loads this plug-in asynchronously if it is not already loaded.

Returns:

 

loadRsrcComponent

void loadRsrcComponent(strRsrcId : String | jsx3.amp.Resource, objParent : jsx3.app.Model, bPaint : boolean)
Loads the contents of a plug-in resource as a GUI component. The resource should be an XML resource whose data is a GI component file. The resource must be already loaded to call this method. This method loads the component with this plug-in as the URI resolver. Therefore, any relative paths in the component will be resolved relative to the directory of this plug-in.

Once the component is loaded, this method defines a getPlugIn() method on the root component object that returns this component. In addition, if the root component object defines an onRsrcLoad() method, that method is called.

Parameters:

strRsrcId
objParentthe GUI component into which to load the resource.
bPaintwhether to paint the loaded resource (default is true).

onExtension

void onExtension(objExtPt : jsx3.amp.ExtPoint, arrExts : Array<jsx3.amp.Ext>)
Called (after this plug-in is instantiated) any time extensions are registered for an extension point of this plug-in. Subclasses may override this method to provide custom behavior but should call jsxsuper to ensure that the EXTENDED event is published.

Parameters:

objExtPt
arrExts

onLoaded

void onLoaded()
Called when all the resources of this plug-in have loaded. Subclasses may override this method to provide custom behavior.

onRegister

void onRegister()
Calls when this plug-in is registered with its engine. Subclasses may override this method to provide custom behavior.

onStartup

void onStartup()
Called when the engine of this plug-in has completely registered all plug-ins. Subclasses may override this method to provide custom behavior.

regBindExpr

void regBindExpr(expression : String, handler : Function)
Registers a function to be called when the value of a binding expression changes.

The binding expression should begin with a '{' and end with a '}'. The expression is parsed for any tokens that match a bindable property of this object. handler will be invoked any time one of these bindable properties changes value. This function is passed the value of the binding expression. The binding expression is evaluated in the context of this object. The "this" keyword is optional in the expression because the expression is evaluated inside of a with block.

Parameters:

expressiona valid binding expression.
handler

See Also:


relativizeURI

jsx3.net.URI relativizeURI(strURI : String | jsx3.net.URI, bRel : boolean)
Implements jsx3.net.URIResolver.

Parameters:

strURI
bRel

Returns:

 

Overrides:


resolveURI

jsx3.net.URI resolveURI(strURI : String | jsx3.net.URI)
Implements jsx3.net.URIResolver.

Parameters:

strURI

Returns:

 

Overrides:


setData

void setData(objElm : jsx3.xml.Entity)
Called after this plug-in is instantiated to provide the plug-in with its XML configuration data. This method is optional for objects used as plug-ins.

Parameters:

objElm

setEngine

void setEngine(objEngine : jsx3.amp.Engine)
Called after this plug-in is instantiated to provide the plug-in with the engine that created it. This method is optional for objects used as plug-ins.

Parameters:

objEngine

setPath

void setPath(strPath : String)
Called after this plug-in is instantiated to provide the plug-in with its path. This method is optional for objects used as plug-ins.

Parameters:

strPath

setResources

void setResources(arrRsrc : Array<jsx3.amp.Resource>)
Called after this plug-in is instantiated to provide the plug-in with the resources defined in the configuration data. This method is optional for objects used as plug-ins.

Parameters:

arrRsrc

jsx3.amp

class Resource

Object
->jsx3.lang.Object
  ->jsx3.amp.Resource

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Resource
extends jsx3.lang.Object
An AMP plug-in resource, such as a JavaScript file or XML file.

Field Summary
static String
Loads a resource before the plug-in is instantiated and registered.
static String
Waits for a resource to be loaded programatically some time after the plug-in loads.
static String
Loads a resource before the plug-in loads.
static String
Event subject published when this resource has loaded.
static String
static String
static String
static String
static String
static String
Constructor Summary
void
init(objPlugIn : jsx3.amp.PlugIn, strId : String, elm : jsx3.xml.Element)
Method Summary
void
attr(k : String)
Returns the value of any attribute of the XML declaration of this resource.
jsx3.xml.Document | jsx3.app.Properties | jsx3.app.PropsBundle
getData(bClear : boolean)
Returns the data associated with this resource.
String
Returns the full ID of this resource, which is unique to the entire AMP engine.
String
Returns the load type, such as LOAD_NORMAL.
String
Returns the ID Of this resource, which is unique among all resources of the same plug-in.
Array<String>
Returns the list of locale keys for which this resources is localized.
String
Returns the path of this resource, which is relative to the directory of the plug-in owning this resource.
String
Returns the path of the best localized version of this resource for objLocale.
jsx3.amp.PlugIn
Returns the plug-in that owns this resource.
String
Returns the resource type, such as TYPE_SCRIPT.
boolean
jsx3.$AsyncRV
Asynchronously loads this resource if it is not already loaded.
jsx3.$AsyncRV
Returns an asynchronous return value that completes when this resource is loaded.
jsx3.xml.Entity
xml()
Returns the XML declaration of this resource as passed to the constructor.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

LOAD_EARLY

static String LOAD_EARLY
Loads a resource before the plug-in is instantiated and registered.

LOAD_MANUAL

static String LOAD_MANUAL
Waits for a resource to be loaded programatically some time after the plug-in loads.

LOAD_NORMAL

static String LOAD_NORMAL
Loads a resource before the plug-in loads.

READY

static String READY
Event subject published when this resource has loaded.

TYPE_BUNDLE

static final String TYPE_BUNDLE

TYPE_CSS

static final String TYPE_CSS

TYPE_JSS

static final String TYPE_JSS

TYPE_SCRIPT

static final String TYPE_SCRIPT

TYPE_XML

static final String TYPE_XML

TYPE_XSL

static final String TYPE_XSL
Constructor Detail

init

void init(objPlugIn : jsx3.amp.PlugIn, strId : String, elm : jsx3.xml.Element)

Parameters:

objPlugInthe plug-in owning the resource.
strIdthe ID of the resource. This ID is unique among all resources of the same plug-in.
elmthe XML declaration of the resource.
Method Detail

attr

void attr(k : String)
Returns the value of any attribute of the XML declaration of this resource.

Parameters:

kthe attribute name.

getData

jsx3.xml.Document | jsx3.app.Properties | jsx3.app.PropsBundle getData(bClear : boolean)
Returns the data associated with this resource. Only resources of type xml, xsl, jss, and propsbundle will return a defined value.

Parameters:

bClearif true then delete the reference to the data object in order to allow garbage collection.

Returns:

 

getId

String getId()
Returns the full ID of this resource, which is unique to the entire AMP engine.

Returns:

 

getLoadType

String getLoadType()
Returns the load type, such as LOAD_NORMAL. The load type is defined using the load attribute of the resource XML declaration.

Returns:

 

See Also:

, ,

getLocalId

String getLocalId()
Returns the ID Of this resource, which is unique among all resources of the same plug-in.

Returns:

 

getLocales

Array<String> getLocales()
Returns the list of locale keys for which this resources is localized. This is equal to the locales attribute of the resource, split by whitespace.

Returns:

 

getPath

String getPath()
Returns the path of this resource, which is relative to the directory of the plug-in owning this resource. The resource type is defined by the id attribute of the resource XML declaration.

Returns:

 

getPathForLocale

String getPathForLocale(objLocale : jsx3.util.Locale)
Returns the path of the best localized version of this resource for objLocale.

Parameters:

objLocale

Returns:

 

getPlugIn

jsx3.amp.PlugIn getPlugIn()
Returns the plug-in that owns this resource.

Returns:

 

getType

String getType()
Returns the resource type, such as TYPE_SCRIPT. The resource type is defined by the element node name of the resource XML declaration.

Returns:

 

isLoaded

boolean isLoaded()

Returns:

 

load

asynchronous jsx3.$AsyncRV load()
Asynchronously loads this resource if it is not already loaded.

Returns:

 

See Also:


loaded

asynchronous jsx3.$AsyncRV loaded()
Returns an asynchronous return value that completes when this resource is loaded.

Returns:

 

See Also:


xml

jsx3.xml.Entity xml()
Returns the XML declaration of this resource as passed to the constructor.

Returns:

 

jsx3.amp

class XML

Object
->jsx3.lang.Object
  ->jsx3.amp.XML

class XML
extends jsx3.lang.Object
An XML wrapper that can be backed either by a real XML node or by a nested object structure.

To wrap a nested object structure, pass an object to the constructor with the following format:

Constructor Summary
void
Method Summary
String
attr(a : String)
Returns an attribute of this element.
jsx3.amp.XML
child(name : String)
Returns a child element of this element whose base name is equal to name.
jsx3.$Array<jsx3.amp.XML>
Returns this child elements of this element.
String
Returns the base name of this element.
String
Returns the node value of this element.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(elm : jsx3.xml.Entity | Object)

Parameters:

elm
Method Detail

attr

String attr(a : String)
Returns an attribute of this element.

Parameters:

athe name of the attribute.

Returns:

the value of the attribute.  

child

jsx3.amp.XML child(name : String)
Returns a child element of this element whose base name is equal to name.

Parameters:

name

Returns:

 

children

jsx3.$Array<jsx3.amp.XML> children()
Returns this child elements of this element.

Returns:

 

nname

String nname()
Returns the base name of this element.

Returns:

the base name.  

value

String value()
Returns the node value of this element.

Returns:

 

package jsx3.amp.util

The standard library of AMP application utility classes. Classes in this package are loaded via AMP plug-ins.

Since:

3.7

Class Summary
jsx3.amp.util.Menu
A managed menu.
jsx3.amp.util.MenuItem
A managed menu item.
jsx3.amp.util.MenuManager
Manages a set of menus.
jsx3.amp.util.Prefs
A preferences panel.
jsx3.amp.util.PrefsPane
A pane in a preferences panel.
jsx3.amp.util.ToolbarItem
Manages a toolbar.
jsx3.amp.util.ToolbarManager
Manages a toolbar.
jsx3.amp.util.Wizard
A wizard.
jsx3.amp.util.WizardPane
A pane of a wizard.

jsx3.amp.util

class Menu

Object
->jsx3.lang.Object
  ->jsx3.amp.util.MenuItem
    ->jsx3.amp.util.Menu

class Menu
extends jsx3.amp.util.MenuItem
A managed menu. Provided by the jsx3.amp.util.menumgr plug-in.

See Also:

jsx3.amp.util.MenuManager

Constructor Summary
void
init(objExt : jsx3.amp.Ext, objElm : jsx3.amp.XML)
The instance initializer.
Method Summary
void
addItem(objItem : jsx3.amp.util.MenuItem, strSection : String)
Adds an item to this menu.
void
addSection(strId : String, bDivider : boolean)
Adds a logical section to this menu.
String
Returns the ID of this menu.
jsx3.amp.util.MenuItem
getItem(id : String)
Returns the item in this menu whose ID is equal to id.
jsx3.$Array<jsx3.amp.util.MenuItem>
Returns all items in this menu.
jsx3.gui.Menu
Returns the native GI menu that was rendered for this AMP menu.
String
Returns the path of this menu.
jsx3.xml.Document
Returns the CDF data source for this menu.
void
onShow(objMenu : jsx3.gui.Menu, objElm : jsx3.xml.Entity)
Called just before this menu is expanded.
Methods Inherited From jsx3.amp.util.MenuItem
attr, execute, getExt, getHotKey, getImg, getLabel, getMenu, getRootMenu, getTip, isEnabled, isSelected
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objExt : jsx3.amp.Ext, objElm : jsx3.amp.XML)
The instance initializer.

Parameters:

objExt
objElm
Method Detail

addItem

void addItem(objItem : jsx3.amp.util.MenuItem, strSection : String)
Adds an item to this menu.

Parameters:

objItemthe item to add.
strSectionthe section ID.

addSection

void addSection(strId : String, bDivider : boolean)
Adds a logical section to this menu.

Parameters:

strIdthe section ID.
bDividerwhether the section begins with a visual dividing line.

getId

String getId()
Returns the ID of this menu.

Returns:

 

Overrides:


getItem

jsx3.amp.util.MenuItem getItem(id : String)
Returns the item in this menu whose ID is equal to id.

Parameters:

id

Returns:

 

getItems

jsx3.$Array<jsx3.amp.util.MenuItem> getItems()
Returns all items in this menu.

Returns:

 

getNativeMenu

jsx3.gui.Menu getNativeMenu()
Returns the native GI menu that was rendered for this AMP menu.

Returns:

 

getPath

String getPath()
Returns the path of this menu.

Returns:

 

Overrides:


getXML

jsx3.xml.Document getXML()
Returns the CDF data source for this menu. If this is a nested menu then this XML will be inserted into the XML document of the base GI Menu.

This method is the bridge between the object-oriented AMP definition of a menu and the XML-based GI definition of a menu.

Returns:

 

onShow

void onShow(objMenu : jsx3.gui.Menu, objElm : jsx3.xml.Entity)
Called just before this menu is expanded. This method may modify any of the XML inside objElm, for example by enabling or selecting menu items or generating menu items on the fly.

Parameters:

objMenu
objElm

jsx3.amp.util

class MenuItem

Object
->jsx3.lang.Object
  ->jsx3.amp.util.MenuItem

Direct Known Subclasses:

jsx3.amp.util.Menu

class MenuItem
extends jsx3.lang.Object
A managed menu item. Provided by the jsx3.amp.util.menumgr plug-in.

See Also:

jsx3.amp.util.MenuManager

Constructor Summary
void
init(objExt : jsx3.amp.Ext, objData : jsx3.amp.XML)
The instance initializer.
Method Summary
String
attr(strKey : String)
Returns an attribute of the XML declaration of this menu item.
void
Executes this menu item.
jsx3.amp.Ext
Returns the extension that defined this menu item.
String
Returns the accelerator key code of this menu item.
String
Returns the full ID of this menu item.
String
Returns the resolved image path of this item.
String
Returns the label of this menu item.
jsx3.amp.util.Menu
Returns the menu that contains this menu item.
String
Returns the path of this menu item.
jsx3.amp.util.Menu
String
Returns the tip of this menu item.
boolean
Returns whether this menu item is enabled.
boolean
Returns whether this menu item is selected.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objExt : jsx3.amp.Ext, objData : jsx3.amp.XML)
The instance initializer.

Parameters:

objExt
objData
Method Detail

attr

String attr(strKey : String)
Returns an attribute of the XML declaration of this menu item.

Parameters:

strKey

Returns:

 

execute

void execute()
Executes this menu item. If the execute attribute is not empty then the plug-in that declared this menu item is loaded. Once the plug-in loads the contents of the execute attribute are execute in the context of the extension that defined this menu item.

getExt

jsx3.amp.Ext getExt()
Returns the extension that defined this menu item.

Returns:

 

getHotKey

String getHotKey()
Returns the accelerator key code of this menu item.

Returns:

 

getId

String getId()
Returns the full ID of this menu item.

Returns:

 

getImg

String getImg()
Returns the resolved image path of this item.

Returns:

 

getLabel

String getLabel()
Returns the label of this menu item.

Returns:

 

getMenu

jsx3.amp.util.Menu getMenu()
Returns the menu that contains this menu item.

Returns:

 

getPath

String getPath()
Returns the path of this menu item.

Returns:

 

getRootMenu

jsx3.amp.util.Menu getRootMenu()

Returns:

 

getTip

String getTip()
Returns the tip of this menu item.

Returns:

 

isEnabled

boolean isEnabled()
Returns whether this menu item is enabled. This implementation interprets bind expressions in the enabled attribute of the item definition. Otherwise this method returns true.

Returns:

 

isSelected

boolean isSelected()
Returns whether this menu item is selected. This implementation interprets bind expressions in the selected attribute of the item definition. Otherwise this method returns false.

Returns:

 

jsx3.amp.util

class MenuManager

Object
->jsx3.lang.Object
  ->jsx3.amp.util.MenuManager

class MenuManager
extends jsx3.lang.Object
Manages a set of menus. Provided by the jsx3.amp.util.menumgr plug-in.

Constructor Summary
void
The instance initializer.
Method Summary
void
Adds a menu item to this manager.
void
Adds a menu to this manager.
void
addMenuBar(strPath : String, objContainer : jsx3.app.Model)
Adds a menu bar to this manager.
void
Paints all the menus in this manager into their respective menu bars.
void
getMenu(strPath : String)
Returns the menu with full path strPath.
jsx3.$Array<jsx3.amp.util.Menu>
Returns all the menus in this manager.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init()
The instance initializer.
Method Detail

addItem

void addItem(objItem : jsx3.amp.util.MenuItem)
Adds a menu item to this manager.

Parameters:

objItem

addMenu

void addMenu(objMenu : jsx3.amp.util.Menu)
Adds a menu to this manager.

Parameters:

objMenu

addMenuBar

void addMenuBar(strPath : String, objContainer : jsx3.app.Model)
Adds a menu bar to this manager. Any menu encountered at strPath will be inserted into the menu bar.

Parameters:

strPaththe menu bar path.
objContainerthe menu bar GUI object.

finishInit

void finishInit()
Paints all the menus in this manager into their respective menu bars.

getMenu

void getMenu(strPath : String)
Returns the menu with full path strPath.

Parameters:

strPath

getMenus

jsx3.$Array<jsx3.amp.util.Menu> getMenus()
Returns all the menus in this manager.

Returns:

 

jsx3.amp.util

class Prefs

Object
->jsx3.lang.Object
  ->jsx3.amp.util.Prefs

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Prefs
extends jsx3.lang.Object
A preferences panel. Provided by the jsx3.amp.util.prefspanel plug-in.

Field Summary
static String
Event subject published when a preferences panel is saved.
static String
Event subject published when the active pane of a preferences panel is changed.
static String
Event subject published when a preferences panel is closed.
Constructor Summary
void
The instance initializer.
Method Summary
void
Adds a prefs pane to this controller.
void
Saves the state of the current pane.
boolean
Returns whether to collapse the left side pane list.
void
renderIn(objParent : jsx3.gui.Model, intPaneToShow : int | jsx3.amp.util.PrefsPane)
Renders the preferences panel in objParent.
void
Saves the state of the current pane and closes this panel.
void
setCollapse(bCollapse : boolean)
Sets whether to collapse the left side pane list.
jsx3.$AsyncRV
showPane(objPane : jsx3.amp.util.PrefsPane | int, bForce : boolean)
Displays a prefs pane in the edit area.
jsx3.$AsyncRV
unload(bForce : boolean)
Removes this preferences panel from the view.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

SAVE

static String SAVE
Event subject published when a preferences panel is saved.

SWITCH

static String SWITCH
Event subject published when the active pane of a preferences panel is changed.

UNLOAD

static String UNLOAD
Event subject published when a preferences panel is closed.
Constructor Detail

init

void init()
The instance initializer.
Method Detail

addPane

void addPane(objPane : jsx3.amp.util.PrefsPane)
Adds a prefs pane to this controller. This method may be called either before or after renderIn() has been called.

Parameters:

objPanethe pane to add.

apply

void apply()
Saves the state of the current pane.

getCollapse

boolean getCollapse()
Returns whether to collapse the left side pane list.

Returns:

 

renderIn

void renderIn(objParent : jsx3.gui.Model, intPaneToShow : int | jsx3.amp.util.PrefsPane)
Renders the preferences panel in objParent.

Parameters:

objParentthe parent to load this panel into.
intPaneToShowoptionally, the pane to reveal initially.

save

void save()
Saves the state of the current pane and closes this panel.

setCollapse

void setCollapse(bCollapse : boolean)
Sets whether to collapse the left side pane list.

Parameters:

bCollapse

showPane

asynchronous jsx3.$AsyncRV showPane(objPane : jsx3.amp.util.PrefsPane | int, bForce : boolean)
Displays a prefs pane in the edit area. Unloads the current prefs pane if necessary. If the current prefs pane is dirty, the user will be prompted to save or discard changes before the prefs pane is switched.

The asynchronous return value is true only if the pane was shown successfully.

Parameters:

objPanethe pane to switch to.
bForceif true, the current pane is unloaded without saving changes.

Returns:

 

unload

asynchronous jsx3.$AsyncRV unload(bForce : boolean)
Removes this preferences panel from the view.

The asynchronous return value is true only if the preferences panel was unloaded successfully.

Parameters:

bForcewhether to force the removal even if there are unsaved changes.

Returns:

 

jsx3.amp.util

class PrefsPane

Object
->jsx3.lang.Object
  ->jsx3.amp.util.PrefsPane

All Implemented Interfaces:

jsx3.util.EventDispatcher

class PrefsPane
extends jsx3.lang.Object
A pane in a preferences panel. Provided by the jsx3.amp.util.prefspanel plug-in.

Field Summary
static String
Event subject published when the state of a preference pane is dirtied.
static String
Event subject published when a preference pane is saved.
Constructor Summary
void
init(ext : jsx3.amp.Ext, obj : jsx3.amp.XML)
The instance initializer.
Method Summary
String
Returns the description of this pane.
jsx3.app.Model
Returns the object in the UI of this pane that should get focus when this pane is first revealed.
String
Returns the resolved path of the image of this pane.
Object
getProperty(strId : String)
Returns an arbitrary property of this pane.
String
Returns the title of this pane.
jsx3.app.Model
Returns the root component of this pane once it is rendered.
boolean
Returns whether this pane has unsaved changes.
jsx3.$AsyncRV
Saves the state of this pane.
void
setDirty(bDirty : boolean)
Sets whether this pane has unsaved changes.
void
setProperty(strId : String, objValue : Object)
Sets an arbitrary property of this pane.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

DIRTIED

static String DIRTIED
Event subject published when the state of a preference pane is dirtied.

SAVED

static String SAVED
Event subject published when a preference pane is saved.
Constructor Detail

init

void init(ext : jsx3.amp.Ext, obj : jsx3.amp.XML)
The instance initializer. The obj parameter must define an attribute, resource, which is the name of an XML resource of ext. This resource will be loaded as the UI component of this pane. The root object of this component file may define the following methods:
  • getFirstResponder() : jsx3.app.Model — returns the object that should be focused when the pane is revealed.
  • loadPrefs() : void — restores the state of the pane before it is revealed.
  • savePrefs() : void | Object{title, message} — saves the state of the pane and optionally returns a title and message to be shown in an alert dialog.

Parameters:

extthe AMP extension declaring this pane.
objthe XML declaration of the extension.
Method Detail

getDescription

String getDescription()
Returns the description of this pane.

Returns:

 

getFirstResponder

jsx3.app.Model getFirstResponder()
Returns the object in the UI of this pane that should get focus when this pane is first revealed. This method delegates to the method getFirstResponder() of the root UI component for this pane, if that method is defined.

Returns:

 

getImage

String getImage()
Returns the resolved path of the image of this pane.

Returns:

 

getProperty

Object getProperty(strId : String)
Returns an arbitrary property of this pane.

Parameters:

strId

Returns:

 

getTitle

String getTitle()
Returns the title of this pane.

Returns:

 

getUI

jsx3.app.Model getUI()
Returns the root component of this pane once it is rendered.

Returns:

 

isDirty

boolean isDirty()
Returns whether this pane has unsaved changes.

Returns:

 

save

asynchronous jsx3.$AsyncRV save()
Saves the state of this pane. This method delegates to the savePrefs() method of the root UI component of this pane.

Returns:

 

setDirty

void setDirty(bDirty : boolean)
Sets whether this pane has unsaved changes.

Parameters:

bDirty

setProperty

void setProperty(strId : String, objValue : Object)
Sets an arbitrary property of this pane. This method may be used for saving state.

Parameters:

strId
objValue

jsx3.amp.util

class ToolbarItem

Object
->jsx3.lang.Object
  ->jsx3.amp.util.ToolbarItem

class ToolbarItem
extends jsx3.lang.Object
Manages a toolbar. Provided by the jsx3.amp.util.toolbarmgr plug-in.

Constructor Summary
void
init(ext : jsx3.amp.Ext, xml : jsx3.amp.Xml)
The instance initializer.
Method Summary
String
Returns the resolved image path of this toolbar item.
String
Returns the section of this toolbar item.
String
Returns the tip of this toolbar item.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(ext : jsx3.amp.Ext, xml : jsx3.amp.Xml)
The instance initializer.

Parameters:

ext
xml
Method Detail

getImg

String getImg()
Returns the resolved image path of this toolbar item.

Returns:

 

getSection

String getSection()
Returns the section of this toolbar item.

Returns:

 

getTip

String getTip()
Returns the tip of this toolbar item.

Returns:

 

jsx3.amp.util

class ToolbarManager

Object
->jsx3.lang.Object
  ->jsx3.amp.util.ToolbarManager

class ToolbarManager
extends jsx3.lang.Object
Manages a toolbar. Provided by the jsx3.amp.util.toolbarmgr plug-in.

Constructor Summary
void
init(objToolbar : jsx3.gui.WindowBar)
The instance initializer.
Method Summary
void
void
addSection(strName : String, bDivider : boolean)
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objToolbar : jsx3.gui.WindowBar)
The instance initializer.

Parameters:

objToolbar
Method Detail

addItem

void addItem(objItem : jsx3.amp.util.ToolbarItem)

Parameters:

objItem

addSection

void addSection(strName : String, bDivider : boolean)

Parameters:

strName
bDivider

jsx3.amp.util

class Wizard

Object
->jsx3.lang.Object
  ->jsx3.amp.util.Wizard

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Wizard
extends jsx3.lang.Object
A wizard. Provided by the jsx3.amp.util.wizard plug-in.

Field Summary
static String
Event subject published when a wizard is cancelled.
static String
Event subject published when a wizard is finished.
static String
Event subject published when a wizard advances to the next pane.
static String
Event subject published when a wizard advances to the previous pane.
Constructor Summary
void
The instance initializer.
Method Summary
void
Adds a pane to this wizard.
void
Invokes the cancel button.
void
Invokes the finish button.
jsx3.amp.util.WizardPane
getPane(index : int)
Returns a pane of this wizard by its index.
int
Returns the number of panes in this wizard.
int
Returns the index of a pane of this wizard.
Object
Returns the wizard session object.
void
Invokes the next button.
void
Invokes the previous button.
void
removePane(index : int)
Removes a pane from this wizard by its list index.
void
renderIn(objContainer : jsx3.app.Model)
Renders the wizard UI as a child of objContainer.
void
setButtonState(previous : boolean, next : boolean, finish : boolean, cancel : boolean)
Updates the enabled button states of the four wizard buttons.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

CANCEL

static String CANCEL
Event subject published when a wizard is cancelled.

FINISH

static String FINISH
Event subject published when a wizard is finished.

NEXT

static String NEXT
Event subject published when a wizard advances to the next pane.

PREVIOUS

static String PREVIOUS
Event subject published when a wizard advances to the previous pane.
Constructor Detail

init

void init()
The instance initializer.
Method Detail

addPane

void addPane(p : jsx3.amp.util.WizardPane)
Adds a pane to this wizard.

Parameters:

p

cancel

void cancel()
Invokes the cancel button.

finish

void finish()
Invokes the finish button.

getPane

jsx3.amp.util.WizardPane getPane(index : int)
Returns a pane of this wizard by its index.

Parameters:

index

Returns:

 

getPaneCount

int getPaneCount()
Returns the number of panes in this wizard.

Returns:

 

getPaneIndex

int getPaneIndex(p : jsx3.amp.util.WizardPane)
Returns the index of a pane of this wizard.

Parameters:

p

Returns:

 

getSession

Object getSession()
Returns the wizard session object. The session can be used by wizard panes to store arbitrary data for the duration of the wizard.

Returns:

 

next

void next()
Invokes the next button.

previous

void previous()
Invokes the previous button.

removePane

void removePane(index : int)
Removes a pane from this wizard by its list index.

Parameters:

index

renderIn

void renderIn(objContainer : jsx3.app.Model)
Renders the wizard UI as a child of objContainer.

Parameters:

objContainer

setButtonState

void setButtonState(previous : boolean, next : boolean, finish : boolean, cancel : boolean)
Updates the enabled button states of the four wizard buttons.

Parameters:

previous
next
finish
cancel

jsx3.amp.util

class WizardPane

Object
->jsx3.lang.Object
  ->jsx3.amp.util.WizardPane

All Implemented Interfaces:

jsx3.util.EventDispatcher

class WizardPane
extends jsx3.lang.Object
A pane of a wizard. Provided by the jsx3.amp.util.wizard plug-in.

Constructor Summary
jsx3.app.Model
The instance initializer.
Method Summary
jsx3.app.Model
Returns the object in the UI of this pane that should be focused when the pane is revealed.
String
Returns the title of this pane.
jsx3.app.Model
Returns the root UI component of this pane once it has been rendered.
jsx3.amp.util.Wizard
Returns the wizard owning this pane.
boolean
Returns true if the cancel button should be enabled.
boolean
Returns true if the finish button should be enabled.
boolean
Returns true if the next button should be enabled.
boolean
Returns true if the previous button should be enabled.
void
onEnter(objSession : Object)
Called when this pane is revealed.
void
onExit(objSession : Object)
Called when this pane is hidden.
void
Called when the UI requests continuing to the next pane.
void
Called when the UI requests backtracking to the previous pane.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

jsx3.app.Model init(data : jsx3.xml.Entity | jsx3.amp.Resource, resolver : jsx3.amp.PlugIn)
The instance initializer.

Parameters:

datathe UI component that renders this pane.
resolverthe plug-in against which to resolve paths in the UI component.

Returns:

 
Method Detail

getFirstResponder

jsx3.app.Model getFirstResponder()
Returns the object in the UI of this pane that should be focused when the pane is revealed. This method delegates to the getFirstResponder() method of the UI component, if that method is defined.

Returns:

 

getTitle

String getTitle()
Returns the title of this pane.

Returns:

 

getUI

jsx3.app.Model getUI()
Returns the root UI component of this pane once it has been rendered.

Returns:

 

getWizard

jsx3.amp.util.Wizard getWizard()
Returns the wizard owning this pane.

Returns:

 

mayCancel

boolean mayCancel()
Returns true if the cancel button should be enabled.

Returns:

 

mayFinish

boolean mayFinish()
Returns true if the finish button should be enabled.

Returns:

 

mayNext

boolean mayNext()
Returns true if the next button should be enabled.

Returns:

 

mayPrevious

boolean mayPrevious()
Returns true if the previous button should be enabled.

Returns:

 

onEnter

void onEnter(objSession : Object)
Called when this pane is revealed. Calls the onReveal() method of the root UI component, if that method is defined.

Parameters:

objSession

onExit

void onExit(objSession : Object)
Called when this pane is hidden. Calls the onConceal() method of the root UI component, if that method is defined.

Parameters:

objSession

onNext

void onNext()
Called when the UI requests continuing to the next pane. This pane may veto such a change by returning an object with the ok field equal to false.

Returns:

{ok:Boolean, alert:Boolean, title:String, message:String}  

onPrevious

void onPrevious()
Called when the UI requests backtracking to the previous pane. This pane may veto such a change by returning an object with the ok field equal to false.

Returns:

{ok:Boolean, alert:Boolean, title:String, message:String}  

package jsx3.app

Application layer classes.

Class Summary
jsx3.app.AddIn
A class that represents a JSX add-in.
jsx3.app.Cache
Provides cached access to XML and XSL data.
jsx3.app.DOM
Registers all DOM nodes in an instance of jsx3.app.Server and publishes related events.
jsx3.app.Model
The abstract base class that defines the JSX DOM.
jsx3.app.Monitor
A logging handler that can be instantiated per JSX application and displays logging messages in a separate browser window while an application is running.
jsx3.app.Properties
Represents a repository of dynamic properties.
jsx3.app.PropsBundle
A subclass of jsx3.app.Properties that supports localized properties.
jsx3.app.Server
The controller of the JSX architecture.
jsx3.app.Settings
An object oriented interface onto the XML system settings format.
jsx3.app.UserSettings
Read-Write per-User settings for a particular GI application (server).

jsx3.app

class AddIn

Object
->jsx3.lang.Object
  ->jsx3.app.AddIn

All Implemented Interfaces:

jsx3.net.URIResolver

class AddIn
extends jsx3.lang.Object
A class that represents a JSX add-in. The JSX system creates an instance of this class for every add-in that is loaded.

Since:

3.2

Field Summary
static String
Method Summary
String
String
String
String
jsx3.app.Settings
String
String
jsx3.net.URI
relativizeURI(strURI : String | jsx3.net.URI, bRel : ?)
jsx3.net.URI
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

PROTOTYPES_DIR

static final String PROTOTYPES_DIR
Method Detail

getDescription

String getDescription()

Returns:

 

getId

String getId()

Returns:

 

getKey

String getKey()

Returns:

 

getName

String getName()

Returns:

 

getSettings

jsx3.app.Settings getSettings()

Returns:

 

getUriPrefix

String getUriPrefix()

Returns:

 

Overrides:


getVersion

String getVersion()

Returns:

 

relativizeURI

jsx3.net.URI relativizeURI(strURI : String | jsx3.net.URI, bRel : ?)

Parameters:

strURI
bRel

Returns:

 

Overrides:


resolveURI

jsx3.net.URI resolveURI(strURI : String | jsx3.net.URI)

Parameters:

strURI

Returns:

 

Overrides:


toString

String toString()

Returns:

 

Overrides:


jsx3.app

class Cache

Object
->jsx3.lang.Object
  ->jsx3.app.Cache

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Cache
extends jsx3.lang.Object
Provides cached access to XML and XSL data.

Events

Cache instances publish two types of events for every operation that modifies the contents of the cache. The schemas of the two event types are and

Asynchronous Loading

Cache documents can be loaded asychronously with the getOrOpenAsync() method. This method returns the corresponding document synchronously if it already exists in the cache. If the document does not exist in the cache, then it is loaded asynchronously and the method returns a placeholder document. The namespace URI of this placeholder document is Cache.XSDNS and its root node name is "loading".

Since the cache stores this placeholder document until the document finishes loading, subsequent calls to synchronous APIs (getDocument(), getOrOpenDocument(), etc) may also return the placeholder document. It is therefore important to check the namespace of the returned document when any code uses the asynchronous APIs.

Once a document finishes loading asynchronously the placeholder document is replaced with the loaded document. This change in value causes the cache to publish a pair of events of action Cache.CHANGE. If loading the document fails or times out the placeholder document is instead replaced with another placeholder document. This document also has a URI namespace of Cache.XSDNS. Its root node name may be either "error" or "timeout". If the root node name is "error" then the root node has an attribute, also named "error", which contains the XML error message.

Field Summary
static String
Event action.
static int
The number of milliseconds before asynchronous document loads time out.
static String
Event subject and action.
static String
Event action.
static String
Constructor Summary
void
Creates a new instance of this class.
Method Summary
jsx3.xml.Document
clearById(strId : String)
Removes the document stored in this cache under id strId.
Array<String>
clearByTimestamp(intTimestamp : int | Date)
Removes all documents placed in this cache before intTimestamp.
void
Removes all references to documents contained in this cache.
jsx3.xml.Document
getDocument(strId : String)
Returns the document stored in this cache under id strId.
jsx3.xml.Document
getOrOpenAsync(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Asynchronously loads an xml document and stores it in this cache.
jsx3.xml.Document
getOrOpenDocument(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Retrieves a document from this cache or, if this cache contains no such document, loads the document synchronously and returns it.
int
getTimestamp(strId : String)
Returns the timestamp from when the document stored under id strId was stored in this cache.
boolean
isSystem(strId : String)
Deprecated.
Array<String>
Returns a list of all the keys in this cache instance.
jsx3.xml.Document
openDocument(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Synchronously loads an xml document, stores it in this cache, and returns the loaded document.
void
setDocument(strId : String, objDocument : jsx3.xml.Document)
Stores the document objDocument in this cache under id strId.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

ADD

static final String ADD
Event action.

ASYNC_TIMEOUT

static int ASYNC_TIMEOUT
The number of milliseconds before asynchronous document loads time out.

CHANGE

static final String CHANGE
Event subject and action.

REMOVE

static final String REMOVE
Event action.

XSDNS

static String XSDNS
Constructor Detail

init

void init()
Creates a new instance of this class.
Method Detail

clearById

jsx3.xml.Document clearById(strId : String)
Removes the document stored in this cache under id strId.

Parameters:

strId

Returns:

the remove document, if any.  

clearByTimestamp

Array<String> clearByTimestamp(intTimestamp : int | Date)
Removes all documents placed in this cache before intTimestamp.

Parameters:

intTimestampepoch seconds or a date object.

Returns:

the ids of the removed documents.  

destroy

void destroy()
Removes all references to documents contained in this cache. This cache is no longer usable after calling this method.

getDocument

jsx3.xml.Document getDocument(strId : String)
Returns the document stored in this cache under id strId.

Parameters:

strId

Returns:

the stored document or null if none exists.  

getOrOpenAsync

jsx3.xml.Document getOrOpenAsync(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Asynchronously loads an xml document and stores it in this cache.

Parameters:

strURLurl (relative or absolute) the URI of the document to open.
strIdthe id under which to store the document. If this parameter is not provided, the strURL parameter is used as the id.
objClassjsx3.xml.Document (default value) or one of its subclasses. The class with which to instantiate the new document instance.

Returns:

the document retrieved from the cache or a placeholder document if the document is in the process of loading asynchronously. 

Since:

3.5

getOrOpenDocument

jsx3.xml.Document getOrOpenDocument(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Retrieves a document from this cache or, if this cache contains no such document, loads the document synchronously and returns it.

Parameters:

strURLthe URI of the document.
strIdthe id under which the document is/will be stored. If this parameter is not provided, the strURL parameter is used as the id.
objClassjsx3.xml.Document (default value) or one of its subclasses. The class with which to instantiate the new document instance if a new document is opened.

Returns:

the document retrieved from the cache or loaded.  

getTimestamp

int getTimestamp(strId : String)
Returns the timestamp from when the document stored under id strId was stored in this cache.

Parameters:

strIdthe id under which the document is stored.

Returns:

the timestamp as an integer (epoch seconds) or null if no such document exists in this cache.  

isSystem

boolean isSystem(strId : String)
Deprecated.
returns whether or not the given document in the cache is owned by the system. If no document by the given ID exists, false is returned.

Parameters:

strIdunique identifier for the jsx3.xml.DocumentInstance instance when it was placed in the cache

Returns:

false

keys

Array<String> keys()
Returns a list of all the keys in this cache instance.

Returns:

 

openDocument

jsx3.xml.Document openDocument(strURL : String | jsx3.net.URI, strId : String, objClass : jsx3.lang.Class)
Synchronously loads an xml document, stores it in this cache, and returns the loaded document.

Parameters:

strURLurl (relative or absolute) the URI of the document to open.
strIdthe id under which to store the document. If this parameter is not provided, the strURL parameter is used as the id.
objClassjsx3.xml.Document (default value) or one of its subclasses. The class with which to instantiate the new document instance.

Returns:

the loaded document object.  

setDocument

void setDocument(strId : String, objDocument : jsx3.xml.Document)
Stores the document objDocument in this cache under id strId. If a document already exists in this cache under strId then that document is removed from the cache.

Parameters:

strIdthe id under which to store objDocument.
objDocument

jsx3.app

class DOM

Object
->jsx3.lang.Object
  ->jsx3.app.DOM

All Implemented Interfaces:

jsx3.util.EventDispatcher

class DOM
extends jsx3.lang.Object
Registers all DOM nodes in an instance of jsx3.app.Server and publishes related events. This class keeps all contained JSX objects indexed on id and name.

Field Summary
static int
0
static int
2
static int
1
Constructor Summary
void
The instance initializer.
Method Summary
void
add(objJSX : jsx3.app.Model)
Adds a JSX object to this DOM and indexes it by its id and name.
void
The instance finalizer.
jsx3.app.Model
get(strId : String)
Looks up a DOM object contained in this DOM by id or name.
Array<jsx3.app.Model>
getAllByName(strName : String)
Returns all the DOM nodes in this DOM with a name of strName.
jsx3.app.Model
getById(strId : String)
Looks up a DOM object contained in this DOM by id.
jsx3.app.Model
getByName(strName : String)
Looks up a DOM object contained in this DOM by name.
static String
newId(strNameSpace : String)
Creates a new unique system id.
void
onChange(TYPE : int, JSXPARENTID : String, JSXID : String)
called when a change to the JSX DOM occurs for this server instance (adopt, load, delete, etc); publishes an event object (javascript object) with the following named properties: subject (jsx3.app.DOM.EVENT_CHANGE); type (jsx3.app.DOM.TYPEADD | jsx3.app.DOM.TYPEREMOVE); parentId (id of JSX parent); jsxId (id of element added or removed)
void
onNameChange(objJSX : jsx3.app.Model, oldName : String)
A method that must be called after changing the name of a contained DOM node.
void
Removes a JSX object from this DOM and removes it from the indices.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

TYPEADD

static final int TYPEADD
0

TYPEREARRANGE

static final int TYPEREARRANGE
2

TYPEREMOVE

static final int TYPEREMOVE
1
Constructor Detail

init

void init()
The instance initializer.
Method Detail

add

void add(objJSX : jsx3.app.Model)
Adds a JSX object to this DOM and indexes it by its id and name.

Parameters:

objJSX

destroy

void destroy()
The instance finalizer.

get

jsx3.app.Model get(strId : String)
Looks up a DOM object contained in this DOM by id or name.

Parameters:

strIdeither the id of the object to return or its name.

Returns:

the matching DOM object or null if none found.  

getAllByName

Array<jsx3.app.Model> getAllByName(strName : String)
Returns all the DOM nodes in this DOM with a name of strName. The name index keeps a bucket of DOM nodes for each unique name. Therefore, this method performs efficiently.

Parameters:

strNamethe name of the objects to return.

Returns:

an array of the matching DOM nodes. This return value should not be mutated as that will effect the internal functioning of this DOM. 

Since:

3.2

See Also:


getById

jsx3.app.Model getById(strId : String)
Looks up a DOM object contained in this DOM by id.

Parameters:

strIdthe id of the object to return.

Returns:

the matching DOM object or null if none found.  

getByName

jsx3.app.Model getByName(strName : String)
Looks up a DOM object contained in this DOM by name. It is left to the developer to specify unique names for all DOM nodes that must be accessed in this manner. If more than one DOM nodes exist with a name of strName the behavior of this method is undefined.

Parameters:

strNamethe name of the object to return.

Returns:

the matching DOM object or null if none found. 

See Also:


newId

static String newId(strNameSpace : String)
Creates a new unique system id.

Parameters:

strNameSpacethe application namespace for which to generate the id.

Returns:

 

onChange

void onChange(TYPE : int, JSXPARENTID : String, JSXID : String)
called when a change to the JSX DOM occurs for this server instance (adopt, load, delete, etc); publishes an event object (javascript object) with the following named properties: subject (jsx3.app.DOM.EVENT_CHANGE); type (jsx3.app.DOM.TYPEADD | jsx3.app.DOM.TYPEREMOVE); parentId (id of JSX parent); jsxId (id of element added or removed)

Parameters:

TYPEone of: jsx3.app.DOM.TYPEADD, jsx3.app.DOM.TYPEREMOVE
JSXPARENTIDid of dom parent
JSXIDid of dom element either added or removed

onNameChange

void onNameChange(objJSX : jsx3.app.Model, oldName : String)
A method that must be called after changing the name of a contained DOM node. This method updates the name index appropriately.

Parameters:

objJSX
oldNamethe name before it was changed

remove

void remove(objJSX : jsx3.app.Model)
Removes a JSX object from this DOM and removes it from the indices.

Parameters:

objJSX

jsx3.app

class Model

Object
->jsx3.lang.Object
  ->jsx3.app.Model

All Implemented Interfaces:

jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.gui.Painted, jsx3.gui.Window

abstract class Model
extends jsx3.lang.Object
The abstract base class that defines the JSX DOM. Instances of this class exist as nodes in a tree, each with a single parent and multiple children. This class includes all the methods for querying and manipulating the DOM's tree structure, such as getChild(), adoptChild(), getParent(), etc.

Field Summary
static int
The number of milliseconds before asynchronous component loads time out.
static String
Minimum supported version CIF formatted serialization files
static String
Minimum supported version for serialization files
static int
The normal load type for a DOM branch.
static int
Load type indicating that the DOM branch will deserialize and paint as needed when it becomes visible.
static int
Load type indicating that the DOM branch will paint as needed when it becomes visible.
static int
Load type indicating that the DOM branch will deserialize and paint after its parent deserializes and the call stack resets.
static int
Load type indicating that the DOM branch will paint after its parent paints and the call stack resets.
static int
Load type indicating that the DOM branch will deserialize after its parent deserializes and the call stack resets and will paint after its parent paints and the call stack resets.
static Object<String, boolean>
The allowed meta data fields.
static int
Normal persistance value for a child that will be persisted.
static int
Persistance value fora child that is temporarily part of the DOM tree and will not be persisted.
static int
Persistance value for a child that exists in an external serialization file and is referenced by URI.
static int
Persistance value for a child that exists in an external serialization file and is referenced by URI.
Constructor Summary
void
init(strName : String, strInstanceOf : ?)
The instance initializer.
Method Summary
void
adoptChild(objChild : jsx3.app.Model, bRepaint : boolean, bForce : boolean)
Appends a DOM node to this object after removing the node from its former parent reference.
jsx3.app.Model
doClone(intPersist : int, intMode : int)
Creates and returns an exact replica of the object.
jsx3.app.Model
findAncestor(fctTest : Function, bIncludeSelf : boolean)
Returns the first ancestor passing the given test function.
jsx3.app.Model | Array<jsx3.app.Model>
findDescendants(fctTest : Function, bDepthFirst : boolean, bMultiple : boolean, bShallow : boolean, bIncludeSelf : boolean)
Finds all DOM nodes descending from this DOM node that pass the given test function.
jsx3.app.Model
Returns the first ancestor with the given name.
jsx3.app.Model
Returns the first ancestor of the given type.
jsx3.app.Model
getChild(vntIndexOrName : int | String)
Returns the child DOM node of this node at the given index or with the given name.
int
Returns the zero-based index for this DOM node in relation to its siblings.
Array<jsx3.app.Model>
Returns an array containing all the child DOM nodes of this object.
jsx3.app.Model
getDescendantOfName(strName : String, bDepthFirst : boolean, bChildOnly : boolean)
Finds the first descendant of this DOM node with a the given name.
Array<jsx3.app.Model>
Finds all descendants of the given type.
jsx3.app.Model
Returns the first child.
jsx3.app.Model
Finds the first child of the given type.
String
Returns the help ID of this object.
String
Returns the custom JSX-generated id for the object (i.e.
jsx3.app.Model
Returns the last child.
int
Returns the load type of this DOM node and the descending branch.
String
getMetaValue(strKey : String)
Returns one of the meta data values stored at the top of the serialization file that this object was loaded from.
String
Returns the namespace that distinguishes this object's server (owner) from other server instances.
String
Returns the custom developer-defined name of this object.
jsx3.app.Model
Returns the next sibling.
jsx3.app.Model
Returns the parent DOM node of this object.
int
Returns the persistence bit for this model object.
jsx3.app.Model
Returns the previous sibling.
jsx3.app.Server
Returns an object reference to the server that owns this object.
jsx3.net.URIResolver
Returns the URI resolver for this DOM node.
static String
Deprecated.
boolean
insertBefore(objMoveChild : jsx3.app.Model, objPrecedeChild : jsx3.app.Model, bRepaint : boolean)
Assigns objMoveChild as the previousSibling of objPrecedeChild
jsx3.app.Model
load(strURL : String | jsx3.net.URI, bRepaint : boolean, objResolver : jsx3.net.URIResolver)
Deserializes a JSX serialization file and appends the deserialized objects as children of this DOM node.
jsx3.app.Model
loadAndCache(strURL : String | jsx3.net.URI, bRepaint : boolean, objCache : jsx3.app.Cache, objResolver : jsx3.net.URIResolver)
Loads a component file and caches the document in an XML cache.
jsx3.app.Model
loadXML(strXML : String | jsx3.xml.Document, bRepaint : boolean, objResolver : jsx3.net.URIResolver)
Deserializes a JSX serialization file and appends the deserialized objects as children of this DOM node.
protected void
onAfterAssemble(objParent : jsx3.app.Model, objServer : jsx3.app.Server)
Called during deserialization of this object.
protected void
Called during deserialization of this object.
protected void
onBeforeAssemble(objParent : jsx3.app.Model, objServer : jsx3.app.Server)
Called during deserialization of this object.
protected void
onChangeServer(objNewServer : jsx3.app.Server, objOldServer : jsx3.app.Server)
Called when the server owning this DOM node changes.
void
onChildAdded(objChild : jsx3.gui.Model)
Hook that notifies the model object that a child has been added to it.
protected void
onDestroy(objParent : jsx3.app.Model)
The finalizer method.
protected void
onRemoveChild(objChild : jsx3.app.Model | Array<jsx3.app.Model>, intIndex : int)
Hook that notifies this model object that one of its children has been removed.
protected boolean
onSetChild(objChild : ?)
Hook that allows for a prospective parent DOM node to veto the adoption of a child.
protected boolean
onSetParent(objParent : ?)
Hook that allows for a prospective child DOM node to veto its adoption by a parent.
jsx3.app.Model
Removes a DOM child from this object.
jsx3.app.Model
Removes some or all children of this object.
Array<jsx3.app.Model> | jsx3.app.Model
selectDescendants(strExpr : String, bSingle : boolean)
Select objects from the DOM using a CSS3-like selection syntax.
jsx3.app.Model | boolean
setChild(objChild : jsx3.app.Model, intPersist : int, strSourceURL : String | jsx3.net.URI, strNS : String)
Appends a child DOM node to this parent DOM node.
void
setHelpId(strId : String)
Sets the help ID of this object.
void
setLoadType(intLoadType : int)
Sets the load type of this DOM node and the descending branch.
void
setMetaValue(strKey : String, strValue : String)
setS one of the meta data values stored at the top of a component's serialization file.
void
setName(strName : String)
Sets the custom developer-defined name of this object.
jsx3.app.Model
setPersistence(intPersist : int)
Sets the persistence bit for this model object.
String
Returns a string representation of this object.
String
toXML(objProperties : Object<String, String>)
Returns this object serialized as XML by calling toString() on the result of toXMLDoc() called on this object.
jsx3.xml.Document
toXMLDoc(objProperties : Object<String, String>)
Serializes this object as an XML document.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ASYNC_LOAD_TIMEOUT

static int ASYNC_LOAD_TIMEOUT
The number of milliseconds before asynchronous component loads time out.

CIF_VERSION

static String CIF_VERSION
Minimum supported version CIF formatted serialization files

CURRENT_VERSION

static String CURRENT_VERSION
Minimum supported version for serialization files

LT_NORMAL

static final int LT_NORMAL
The normal load type for a DOM branch. The DOM branch deserializes and paints with its parent.

LT_SHOW_DESER

static final int LT_SHOW_DESER
Load type indicating that the DOM branch will deserialize and paint as needed when it becomes visible. It is left to subclasses of Model to implement this functionality.

LT_SHOW_PAINT

static final int LT_SHOW_PAINT
Load type indicating that the DOM branch will paint as needed when it becomes visible. It is left to subclasses of Model to implement this functionality.

LT_SLEEP_DESER

static final int LT_SLEEP_DESER
Load type indicating that the DOM branch will deserialize and paint after its parent deserializes and the call stack resets.

LT_SLEEP_PAINT

static final int LT_SLEEP_PAINT
Load type indicating that the DOM branch will paint after its parent paints and the call stack resets.

LT_SLEEP_PD

static final int LT_SLEEP_PD
Load type indicating that the DOM branch will deserialize after its parent deserializes and the call stack resets and will paint after its parent paints and the call stack resets.

META_FIELDS

static Object<String, boolean> META_FIELDS
The allowed meta data fields. See getMetaValue() and setMetaValue().

PERSISTEMBED

static final int PERSISTEMBED
Normal persistance value for a child that will be persisted.

PERSISTNONE

static final int PERSISTNONE
Persistance value fora child that is temporarily part of the DOM tree and will not be persisted.

PERSISTREF

static final int PERSISTREF
Persistance value for a child that exists in an external serialization file and is referenced by URI.

PERSISTREFASYNC

static final int PERSISTREFASYNC
Persistance value for a child that exists in an external serialization file and is referenced by URI. The loading of a child with this persistence value will happen asynchronously after the file that references it is loaded.
Constructor Detail

init

void init(strName : String, strInstanceOf : ?)
The instance initializer.

Parameters:

strNamea unique name distinguishing this object from all other JSX GUI objects in the JSX application
strInstanceOf
Method Detail

adoptChild

void adoptChild(objChild : jsx3.app.Model, bRepaint : boolean, bForce : boolean)
Appends a DOM node to this object after removing the node from its former parent reference. If the node to append does not already have a DOM parent, setChild() should be used instead of this method.

Parameters:

objChildthe child to adopt
bRepaintif true or null, the object being adopted will be added to the parent's view via the parent's paintChild() method. This parameter is made available for those situations where a loop is executing and multiple objects are being adopted. As view operations are the most CPU intensive, passing false while looping through a collection of child objects to adopt will improve performance. After the last child is adopted, simply call repaint() on the parent to immediately synchronize the view.
bForceif true, the adoption is forced, even if the parent/child don't accept such adoptions (onSetChild() and onSetParent() will still be called)

See Also:


doClone

jsx3.app.Model doClone(intPersist : int, intMode : int)
Creates and returns an exact replica of the object. The clone will be appended as a new child node of this object's parent node.

Parameters:

intPersistthe persistance value of the clone.
intMode0 for insert as the last child of the parent of this object and paint, 1 for insert as the last child of this parent of this object and do not paint, or 2 for load as a fragment.

Throws:

{jsx3.lang.Exception}if this object has no parent DOM node.

Returns:

the clone. 

findAncestor

jsx3.app.Model findAncestor(fctTest : Function, bIncludeSelf : boolean)
Returns the first ancestor passing the given test function.

Parameters:

fctTesttest function, takes a single jsx3.app.Model parameter and returns true if the node matches.
bIncludeSelfif true, include this object in the search

Returns:

 

findDescendants

jsx3.app.Model | Array<jsx3.app.Model> findDescendants(fctTest : Function, bDepthFirst : boolean, bMultiple : boolean, bShallow : boolean, bIncludeSelf : boolean)
Finds all DOM nodes descending from this DOM node that pass the given test function. Results are guaranteed to be returned in order according to the search order used.

Parameters:

fctTesttest function, takes a single jsx3.app.Model parameter and returns true if the node matches.
bDepthFirstspecifies whether to do a depth first or breadth first search.
bMultipleif true, return an array of matches, otherwise just the first match.
bShallowif true, only search direct children.
bIncludeSelfif true, include this node in the search.

Returns:

the match (bMultiple = false) or matches (bMultiple = true).  

getAncestorOfName

jsx3.app.Model getAncestorOfName(strName : String)
Returns the first ancestor with the given name.

Parameters:

strNamethe name to query on.

Returns:

the first ancestor with the given name or null if none found.  

getAncestorOfType

jsx3.app.Model getAncestorOfType(strType : String | Function | jsx3.lang.Class)
Returns the first ancestor of the given type.

Parameters:

strTypethe fully-qualified class name, class constructor function, or jsx3.Class instance.

Returns:

the first ancestor of the given type or null if none found.  

getChild

jsx3.app.Model getChild(vntIndexOrName : int | String)
Returns the child DOM node of this node at the given index or with the given name. If a name is supplied, the children are searched in order and the first matching child is returned.

Parameters:

vntIndexOrNameeither the integer index or the string name of the child.

Returns:

the child at the given index or with the given name, or null if no such child exists.  

getChildIndex

int getChildIndex()
Returns the zero-based index for this DOM node in relation to its siblings.

Returns:

the index or -1 if this object does not have a parent.  

getChildren

Array<jsx3.app.Model> getChildren()
Returns an array containing all the child DOM nodes of this object. The return value is the original array rather than a copy and should not be modified.

Returns:

 

getDescendantOfName

jsx3.app.Model getDescendantOfName(strName : String, bDepthFirst : boolean, bChildOnly : boolean)
Finds the first descendant of this DOM node with a the given name.

Parameters:

strNamethe name to query on.
bDepthFirstspecifies whether to do a depth first or breadth first search.
bChildOnlyif true, only search the children of this DOM node.

Returns:

the descendant with the given name or null if none found.  

getDescendantsOfType

Array<jsx3.app.Model> getDescendantsOfType(strType : String | Function | jsx3.lang.Class, bShallow : boolean)
Finds all descendants of the given type.

Parameters:

strTypethe fully-qualified class name, class constructor function, or jsx3.Class instance.
bShallowif true, only search direct children, not all descendants.

Returns:

an array of matching descendants  

getFirstChild

jsx3.app.Model getFirstChild()
Returns the first child.

Returns:

 

getFirstChildOfType

jsx3.app.Model getFirstChildOfType(strType : String | Function | jsx3.lang.Class, bExact : boolean)
Finds the first child of the given type.

Parameters:

strTypethe fully-qualified class name, class constructor function, or jsx3.Class instance.
bExactif true then only return objects whose class is exactly strType (rather than returning subclasses too).

Returns:

the child of the given type or null if none found.  

getHelpId

String getHelpId()
Returns the help ID of this object.

Returns:

 

Since:

3.5

See Also:


getId

String getId()
Returns the custom JSX-generated id for the object (i.e., _jsx2384098324509823049).

Returns:

JSX id  

getLastChild

jsx3.app.Model getLastChild()
Returns the last child.

Returns:

 

getLoadType

int getLoadType()
Returns the load type of this DOM node and the descending branch. The load type determines how this DOM branch deserializes and paints in relation to its parent DOM node.

Returns:

LT_NORMAL, LT_SLEEP_PAINT, LT_SLEEP_DESER, LT_SLEEP_PD, LT_SHOW_PAINT, or LT_SHOW_DESER

Since:

3.5

See Also:

, , , , ,

getMetaValue

String getMetaValue(strKey : String)
Returns one of the meta data values stored at the top of the serialization file that this object was loaded from.

Parameters:

strKeythe name of the meta data field, one of the keys in META_FIELDS.

Returns:

the meta data value or empty string. 

See Also:


getNS

String getNS()
Returns the namespace that distinguishes this object's server (owner) from other server instances. The namespace is set when this object is bound to a DOM tree.

Returns:

the namespace of the server that owns this object instance.  

getName

String getName()
Returns the custom developer-defined name of this object.

Returns:

 

getNextSibling

jsx3.app.Model getNextSibling()
Returns the next sibling.

Returns:

 

getParent

final jsx3.app.Model getParent()
Returns the parent DOM node of this object.

Returns:

 

getPersistence

int getPersistence()
Returns the persistence bit for this model object.

Returns:

one of PERSISTNONE, PERSISTEMBED, PERSISTREF, PERSISTREFASYNC

See Also:

, , ,

getPreviousSibling

jsx3.app.Model getPreviousSibling()
Returns the previous sibling.

Returns:

 

getServer

jsx3.app.Server getServer()
Returns an object reference to the server that owns this object. This method returns null if this object is part of a DOM fragment. Until an object is added to a DOM tree by passing it as the parameter to setChild(), the object will be a DOM fragment.

Returns:

 

getUriResolver

jsx3.net.URIResolver getUriResolver()
Returns the URI resolver for this DOM node. This method returns the server of this object unless this node or its ancestor was loaded into the DOM with an explicit URI resolver.

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "3.0.00")

Returns:

 

insertBefore

boolean insertBefore(objMoveChild : jsx3.app.Model, objPrecedeChild : jsx3.app.Model, bRepaint : boolean)
Assigns objMoveChild as the previousSibling of objPrecedeChild

Parameters:

objMoveChildthe one being moved. Can belong to this object, another object, or can be a GUI fragment
objPrecedeChildthe one to insert before
bRepaintif false the repaint will be suppressed (useful for multiple obejct updates that would lead to unnecessary updates to the VIEW)

Returns:

true if successful  

load

jsx3.app.Model load(strURL : String | jsx3.net.URI, bRepaint : boolean, objResolver : jsx3.net.URIResolver)
Deserializes a JSX serialization file and appends the deserialized objects as children of this DOM node.

Parameters:

strURLURL (either relative or absolute) of the serialization file to deserialize. This URL is resolved relative to objResolver, if provided, or the URI resolver of this DOM node.
bRepaintif true or null the deserialized objects will be added to the parent's view via the parent object's paintChild() method.
objResolverIf this parameter is provided, strURL is resolved relative to it. Additionally, this resolver is stored as the URI resolver for this DOM node and its descendants.

Throws:

{jsx3.lang.Exception}if strURL is not the URL of a valid XML document.

Returns:

the deserialized object. A serialization file may specify more than one root object, in which case this method returns the first deserialized object. 

See Also:


loadAndCache

jsx3.app.Model loadAndCache(strURL : String | jsx3.net.URI, bRepaint : boolean, objCache : jsx3.app.Cache, objResolver : jsx3.net.URIResolver)
Loads a component file and caches the document in an XML cache. If the component file already exists in the cache then it is loaded from the cache. All component files loaded as a result of this call (referenced files) are also cached. This method is a useful replacement for load() when the same URL will be loaded multiple times in one application.

Parameters:

strURLURL (either relative or absolute) of the serialization file to deserialize. This URL is resolved relative to objResolver, if provided, or the URI resolver of this DOM node.
bRepaintif true or null the deserialized objects will be added to the parent's view via the parent object's paintChild() method.
objCachethe cache to store the component XML documents in. If not provided, the cache of the server of this model object is used.
objResolverIf this parameter is provided, strURL is resolved relative to it. Additionally, this resolver is stored as the URI resolver for this DOM node and its descendants.

Throws:

{jsx3.lang.Exception}if strURL is not the URL of a valid XML document.

Returns:

the deserialized object. A serialization file may specify more than one root object, in which case this method returns the first deserialized object. 

See Also:

,

loadXML

jsx3.app.Model loadXML(strXML : String | jsx3.xml.Document, bRepaint : boolean, objResolver : jsx3.net.URIResolver)
Deserializes a JSX serialization file and appends the deserialized objects as children of this DOM node.

Parameters:

strXMLthe XML content of a JSX serialization file.
bRepaintif true or null the deserialized objects will be added to the parent's view via the parent object's paintChild() method.
objResolver

Throws:

{jsx3.lang.Exception}if strXML is not a valid XML document.

Returns:

the deserialized object. A serialization file may specify more than one root object, in which case this method returns the first deserialized object. 

onAfterAssemble

protected void onAfterAssemble(objParent : jsx3.app.Model, objServer : jsx3.app.Server)
Called during deserialization of this object. This method provides a hook for initializing an object during deserialization since init() is not called. Called after this object has been instantiated and after its fields and children have been assembled.This method is called before this object is attached to the DOM, therefore getParent(), getServer(), getXML(), etc. return null.

Parameters:

objParentthe parent of this object once it is attached to the DOM.
objServerthe server that this DOM object will attach to.

onAfterAttach

protected void onAfterAttach()
Called during deserialization of this object. This method provides a hook for initializing an object during deserialization since init() is not called. Called after this object has been instantiated and after it has been attached to the DOM. Methods overriding this method should usually begin with a call to jsxsuper().

When a new branch is attached to the DOM, this method is executed on each node in the branch. The order is reverse-breadth-first meaning that child nodes are notified from oldest to youngest and before the parent node.

This implementation of this method executes the on-after-deserialize script of this object.

onBeforeAssemble

protected void onBeforeAssemble(objParent : jsx3.app.Model, objServer : jsx3.app.Server)
Called during deserialization of this object. This method provides a hook for initializing an object during deserialization since init() is not called. Called after this object has been instantiated but before its fields and children have been assembled. This method is called before this object is attached to the DOM, therefore getParent(), getServer(), getXML(), etc. return null.

Parameters:

objParentthe parent of this object once it is attached to the DOM.
objServerthe server that this DOM object will attach to.

onChangeServer

protected void onChangeServer(objNewServer : jsx3.app.Server, objOldServer : jsx3.app.Server)
Called when the server owning this DOM node changes.

Parameters:

objNewServer
objOldServer

Since:

3.5

onChildAdded

void onChildAdded(objChild : jsx3.gui.Model)
Hook that notifies the model object that a child has been added to it.

Parameters:

objChildthe added child.

Since:

3.7

onDestroy

protected void onDestroy(objParent : jsx3.app.Model)
The finalizer method. This method provides a hook for subclasses of this class to perform custom logic when an instance of this class is removed from the DOM. Methods that override this method should begin with a call to jsxsuper().

Note that this method is called after this object has been removed from the DOM tree. Therefore this.getParent() and this.getServer() will return null. Use the objParent parameter for access to the DOM tree.

Parameters:

objParentreference to the former parent

onRemoveChild

protected void onRemoveChild(objChild : jsx3.app.Model | Array<jsx3.app.Model>, intIndex : int)
Hook that notifies this model object that one of its children has been removed. This hook exists simply to allow this object to perform cleanup/re-render, and does not provide a veto mechanism. This method is called after the child has been removed from the model (this.getChildren() does not contain objChild) and after the child has been removed from the view (objChild.getRendered() is also null).

This method is only called if the child is being removed from the DOM but this object (the parent) is not being removed. Therefore, this hook cannot be relied upon for garbage collection.

If removeChildren() is called on this object, this hook is called exactly once after all children have been removed. In that case, the first parameter to this method will be the array of children and the second parameter will be null.

In general a method overriding this method should begin by calling jsxsuper.

Parameters:

objChildthe child that was removed
intIndexthe index of the removed child

onSetChild

protected boolean onSetChild(objChild : ?)
Hook that allows for a prospective parent DOM node to veto the adoption of a child.

Parameters:

objChild

Returns:

true to allow the set, false to veto 

onSetParent

protected boolean onSetParent(objParent : ?)
Hook that allows for a prospective child DOM node to veto its adoption by a parent. This method is only called if the prospective parent has not already vetoed the adoption in the onSetChild() method.

Parameters:

objParent

Returns:

true to allow the set, false to veto 

removeChild

jsx3.app.Model removeChild(vntItem : int | jsx3.app.Model)
Removes a DOM child from this object. This method removes the on-screen DHTML of the removed object. The removed child will be completely derefenced from the DOM and will be prepped for garbage collection. If a DOM child must continue to exist after removing it from this parent, adoptChild() should be used instead of this method.

Parameters:

vntItemeither the index of the child to remove or the child itself.

Returns:

this object 

See Also:


removeChildren

jsx3.app.Model removeChildren(arrChildren : Array<int | jsx3.app.Model>)
Removes some or all children of this object.

Parameters:

arrChildrenthe children to remove. If this parameter is not provided then all children are removed.

Returns:

this object. 

See Also:


selectDescendants

Array<jsx3.app.Model> | jsx3.app.Model selectDescendants(strExpr : String, bSingle : boolean)
Select objects from the DOM using a CSS3-like selection syntax. This method considers the DOM tree whose root is this object. The following constructs are supported:
  • jsx3_gui_ClassName - matches objects by their exact class. Replace "." with "_" in the selector.
  • * - matches any object
  • #id - matches objects whose name equals id
  • .class-name - matches objects for which getClassName() is defined and returns a string that contains the token class-name
  • :first and :last - matches objects that are their parents' first and last children
  • :nth(n) and nth-child(n) - matches objects whose child index is equal to n
  • :instanceof(ClassName) - matches objects that are instances of the class or interface ClassName
  • [prop="value"] and [prop*="value"] - matches objects whose value for field prop equals value
  • or, with "*", contains value. The quotes around value are optional.
  • [getter()="value"] and [getter()*="value"] - matches objects whose return value for method getter equals value
  • or, with "*", contains value. The quotes around value are optional.
  • AB - matches objects that match both A and B
  • A B - matches descendants of objects matching A that match B
  • A > B - matches immediate children of objects matching A that match B

Parameters:

strExprthe selection query
bSingleif true, return only the first match.

Throws:

{jsx3.lang.IllegalArgumentException}if strExpr is an invalid selection query.

Returns:

 

Since:

3.8

setChild

jsx3.app.Model | boolean setChild(objChild : jsx3.app.Model, intPersist : int, strSourceURL : String | jsx3.net.URI, strNS : String)
Appends a child DOM node to this parent DOM node. If the child already has a parent, adoptChild() should be used instead to ensure that the child is removed from its current parent.

Parameters:

objChildthe root node of a DOM fragment.
intPersistdefines how the child will be persisted/serialized. The valid values are the four persistence values defined as static fields in this class.
strSourceURLthe path to the serialization file where the child exists. This parameter is only relevant if the given intPersist is PERSISTREF or PERSISTREFASYNC.
strNSthe namespace of the child to append. This parameter is normally not required but is useful when sharing DOM nodes between servers with different namespaces.

Throws:

{jsx3.lang.Exception}if this object is part of a DOM fragment (the namespace is null) and the strNS parameter is not specified.

Returns:

this object or false if the set was vetoed 

See Also:

, , , ,

setHelpId

void setHelpId(strId : String)
Sets the help ID of this object.

Parameters:

strId

Since:

3.5

See Also:


setLoadType

void setLoadType(intLoadType : int)
Sets the load type of this DOM node and the descending branch.

Parameters:

intLoadTypeLT_NORMAL, LT_SLEEP_PAINT, LT_SLEEP_DESER, LT_SLEEP_PD, LT_SHOW_PAINT, or LT_SHOW_DESER.

Since:

3.5

See Also:


setMetaValue

void setMetaValue(strKey : String, strValue : String)
setS one of the meta data values stored at the top of a component's serialization file.

Parameters:

strKeythe name of the meta data field, one of the keys in META_FIELDS
strValuethe new value of the meta data field.

See Also:


setName

void setName(strName : String)
Sets the custom developer-defined name of this object.

Parameters:

strNamea name unique among all DOM nodes currently loaded in the application.

setPersistence

jsx3.app.Model setPersistence(intPersist : int)
Sets the persistence bit for this model object.

Parameters:

intPersistone of PERSISTNONE, PERSISTEMBED, PERSISTREF, PERSISTREFASYNC.

Returns:

this object 

See Also:

, , ,

toString

String toString()
Returns a string representation of this object.

Returns:

 

Overrides:


toXML

String toXML(objProperties : Object<String, String>)
Returns this object serialized as XML by calling toString() on the result of toXMLDoc() called on this object.

Parameters:

objPropertiesname-value pairs that affect the serialization. See toXMLDoc() for a description.

Returns:

this object serialized as an XML string. 

See Also:


toXMLDoc

jsx3.xml.Document toXMLDoc(objProperties : Object<String, String>)
Serializes this object as an XML document.

The objProperties parameter may include the following keys:
  • onafter {String} - the value of the onAfterDeserialize element
  • onbefore {String} - the value of the onBeforeDeserialize element
  • name {String} - the value of the name element
  • icon {String} - the value of the icon element
  • description {String} - the value of the description element
  • children {boolean} - if true the children of this object, rather than this object, are serialized
  • persistall {boolean} - if true all descendants with persistence PERSISTNONE are included in the serialization

Parameters:

objPropertiesname-value pairs that affect the serialization. See above for valid names and how they affect serialization.

Returns:

this object serialized as an XML document.  

jsx3.app

class Monitor

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler
    ->jsx3.util.Logger.FormatHandler
      ->jsx3.app.Monitor

class Monitor
extends jsx3.util.Logger.FormatHandler
A logging handler that can be instantiated per JSX application and displays logging messages in a separate browser window while an application is running.

Since:

3.1

Constructor Summary
void
init(strName : String)
The instance initializer.
Method Summary
boolean
Returns whether this monitor remains invisible until the user types the hotkey ctrl+alt+m in the attached application.
boolean
Returns whether this monitor is disabled when its application is running inside the IDE.
String
Returns the server namespace of this monitor.
void
Writes the formatted logging message to a separate browser window if all relevant conditions are met.
void
setActivateOnHotKey(activateOnHotKey : boolean)
Sets whether this monitor waits for the hotkey ctrl+alt+m before becoming visible.
void
setDisableInIDE(disableInIDE : boolean)
Sets whether this monitor is disabled when its application is running inside the IDE.
void
setServerNamespace(serverNamespace : String)
Sets the server namespace of this monitor.
Methods Inherited From jsx3.util.Logger.FormatHandler
getFormat, setFormat
Methods Inherited From jsx3.util.Logger.Handler
getLevel, getName, isLoggable, setLevel
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(strName : String)
The instance initializer.

Parameters:

strName
Method Detail

getActivateOnHotKey

boolean getActivateOnHotKey()
Returns whether this monitor remains invisible until the user types the hotkey ctrl+alt+m in the attached application. If false this monitor will appear when the application is loaded and anytime the monitor is closed and a logging message is received.

Returns:

 

getDisableInIDE

boolean getDisableInIDE()
Returns whether this monitor is disabled when its application is running inside the IDE.

Returns:

 

getServerNamespace

String getServerNamespace()
Returns the server namespace of this monitor. When an application is created with a namespace equal to this value that application is attached to this monitor and the monitor becomes live.

Returns:

 

handle

void handle(objRecord : jsx3.util.Logger.Record)
Writes the formatted logging message to a separate browser window if all relevant conditions are met.

Parameters:

objRecord

Overrides:


setActivateOnHotKey

void setActivateOnHotKey(activateOnHotKey : boolean)
Sets whether this monitor waits for the hotkey ctrl+alt+m before becoming visible.

Parameters:

activateOnHotKey

setDisableInIDE

void setDisableInIDE(disableInIDE : boolean)
Sets whether this monitor is disabled when its application is running inside the IDE.

Parameters:

disableInIDE

setServerNamespace

void setServerNamespace(serverNamespace : String)
Sets the server namespace of this monitor.

Parameters:

serverNamespace

jsx3.app

class Properties

Object
->jsx3.lang.Object
  ->jsx3.app.Properties

Direct Known Subclasses:

jsx3.app.PropsBundle

class Properties
extends jsx3.lang.Object
Represents a repository of dynamic properties. Dynamic properties are simply name-value pairs. Dynamic properties can be loaded from an XML file in the CDF dynamic property format.

Since:

3.2

Constructor Summary
void
The instance initializer.
Method Summary
void
Adds a parent property repository to this repository.
boolean
containsKey(strKey : String)
Returns whether this property repository contains a particular property.
Object | undefined
get(strKey : String)
Returns the value of a property for a particular key.
Array<String>
Returns a list of all the property keys contained in this repository.
Array<jsx3.app.Properties>
Returns the list of parent repositories of this repository.
void
loadXML(objXML : jsx3.xml.Entity, strId : String)
Loads a set of dynamic properties from an XML document into this repository.
void
remove(strKey : String)
Removes a property from this repository.
void
Removes all parent property repositories.
void
Removes a property repository from the set of parent repositories.
void
set(strKey : String, strValue : Object)
Sets a property in this repository in the global space.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init()
The instance initializer.
Method Detail

addParent

void addParent(objParent : jsx3.app.Properties)
Adds a parent property repository to this repository. get() consults all parents before returning undefined.

Parameters:

objParent

See Also:


containsKey

boolean containsKey(strKey : String)
Returns whether this property repository contains a particular property. Parent repositories are not consulted.

Parameters:

strKeythe property key to query for.

Returns:

true if this repository contains a property with the given key.  

get

Object | undefined get(strKey : String)
Returns the value of a property for a particular key. This method consults the parent repositories as necessary until a property is found. If no property is found, undefined is returned.

Parameters:

strKeythe property key to query for.

Returns:

 

getKeys

Array<String> getKeys()
Returns a list of all the property keys contained in this repository. Parent repositories are not consulted.

Returns:

 

getParents

Array<jsx3.app.Properties> getParents()
Returns the list of parent repositories of this repository.

Returns:

 

loadXML

void loadXML(objXML : jsx3.xml.Entity, strId : String)
Loads a set of dynamic properties from an XML document into this repository. The document should be a shallow CDF document with any number of record elements defined under the root data element.

The following CDF attributes are supported:
  • jsxid – the property key, required.
  • jsxtext – the property value, required.
  • eval – if "1" or "true" the jsxtext attribute is evaluated with JavaScript, optional.

Parameters:

objXML
strIdspecifies the id to store the document under. If none is provided, the default space is used.

remove

void remove(strKey : String)
Removes a property from this repository. The property is removed from all spaces.

Parameters:

strKeythe key of the property to remove.

removeAllParents

void removeAllParents()
Removes all parent property repositories.

removeParent

void removeParent(objParent : jsx3.app.Properties)
Removes a property repository from the set of parent repositories.

Parameters:

objParentthe parent repository to remove.

set

void set(strKey : String, strValue : Object)
Sets a property in this repository in the global space.

Parameters:

strKeythe key of the property to set.
strValuethe value of the property. This value may be null, in which case null will be stored as the property value. This value may not be undefined; use remove() to remove a property value.

See Also:


jsx3.app

class PropsBundle

Object
->jsx3.lang.Object
  ->jsx3.app.Properties
    ->jsx3.app.PropsBundle

class PropsBundle
extends jsx3.app.Properties
A subclass of jsx3.app.Properties that supports localized properties. Using this class, an application can define properties for a number of locales but only load the properties necessary to display a particular locale. Additionally, this class supports fall-through so that if a property is not defined for a particular locale that locale inherits the value from the next most specific locale.

A properties bundle can consist of one or more XML files. The main file, fileName.ext, contains the properties for the default locale, as well as the properties for any number of other locales, and metadata indicating what locales are available external to the main file. The format of this file is:
<data jsxnamespace="propsbundle" locales="externalLocales">
  <!-- the default locale -->
  <locale>
    <record jsxid="propId" jsxtext="propValue"/>
    ...
  </locale>
  <!-- additional locales -->
  <locale key="en_US">
    <record jsxid="propId" jsxtext="propValueEnUs"/>
    ...
  </locale>
  ...
</data>
externalLocales is a comma-separated list of locales that are available for this properties bundle that are defined in separate files. By spreading a properties bundle over many files, loading a bundle for a single locale is optimized. For each locale, locKey, listed in externalLocales, there must be a file fileName.locKey.ext in the same directory as the main bundle file.

Each external file has the same format as the main file except that the locales attribute of the data tag should not be specified. Any number of locales can be defined. The first locale defined should be the locale explicit in the name of the file. Only more specific locales should follow this locale. For example, file props.es.xml, should start by defining locale es and could continue with locales es_ES and es_MX but should not define locales fr or de.

Since:

3.4

Method Summary
static void
clearCache(strPath : String, objCache : jsx3.app.Cache)
Clears all the data stored in the caches internal to this class.
jsx3.app.Locale
Returns the locale for which this properties object was created.
String
Returns the base path of this properties bundle.
static jsx3.app.PropsBundle
getProps(strBasePath : String | jsx3.net.URI, objLocale : jsx3.util.Locale, objCache : jsx3.app.Cache)
Returns a properties object representing a localized view onto a properties bundle.
static jsx3.app.PropsBundle
getPropsAsync(strBasePath : String | jsx3.net.URI, objLocale : jsx3.util.Locale, fctCallback : Function, objCache : jsx3.app.Cache)
Returns a properties object representing a localized view onto a properties bundle.
Methods Inherited From jsx3.app.Properties
addParent, containsKey, get, getKeys, getParents, loadXML, remove, removeAllParents, removeParent, set
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

clearCache

static void clearCache(strPath : String, objCache : jsx3.app.Cache)
Clears all the data stored in the caches internal to this class. Repeated calls to getProps() consult only these caches. If files have changed on disk this method must be called for the return value of getProps() to reflect these changes.

Parameters:

strPathif provided, only clear out the documents stored for the resource at path strPath.
objCacheif provided in addition to strPath, clear out any documents stored in objCache associated with the resource at path strPath.

getLocale

jsx3.app.Locale getLocale()
Returns the locale for which this properties object was created. The value returned by this method is the value sent to the getProps() method and not necessarily the most specific locale for which the properties in this view are defined.

Returns:

 

See Also:


getPath

String getPath()
Returns the base path of this properties bundle.

Returns:

 

getProps

static jsx3.app.PropsBundle getProps(strBasePath : String | jsx3.net.URI, objLocale : jsx3.util.Locale, objCache : jsx3.app.Cache)
Returns a properties object representing a localized view onto a properties bundle.

Parameters:

strBasePaththe relative URI to the main properties file.
objLocalethe locale for which to load the localized properties. If this is not provided, the system locale is used.
objCacheif provided, any loaded XML documents will be placed in this cache.

Returns:

 

getPropsAsync

static jsx3.app.PropsBundle getPropsAsync(strBasePath : String | jsx3.net.URI, objLocale : jsx3.util.Locale, fctCallback : Function, objCache : jsx3.app.Cache)
Returns a properties object representing a localized view onto a properties bundle.

Parameters:

strBasePaththe relative URI to the main properties file.
objLocalethe locale for which to load the localized properties. If this is not provided, the system locale is used.
fctCallbacka callback function to call when the properties bundle has loaded.
objCacheif provided, any loaded XML documents will be placed in this cache.

Returns:

 

Since:

3.6

jsx3.app

class Server

Object
->jsx3.lang.Object
  ->jsx3.app.Server

All Implemented Interfaces:

jsx3.gui.Alerts, jsx3.net.URIResolver, jsx3.util.EventDispatcher

class Server
extends jsx3.lang.Object
The controller of the JSX architecture.

Field Summary
jsx3.app.Cache
Deprecated. Use Server.getCache()
jsx3.app.DOM
Deprecated. Use Server.getDOM()
Object<String, String>
Deprecated. Use Server.getEnv()
static String
The subject of an event that instances of this class publish when a context help hot key is pressed in the context of a DOM node that has a help ID.
static String
The subject of an event that jsx3.app.Server publishes when an instance of this class is created.
jsx3.gui.Block
Deprecated. Use Server.getBodyBlock()
jsx3.gui.Block
Deprecated. Use Server.getRootBlock()
Constructor Summary
void
init(strAppPath : String, objGUI : HTMLElement, bPaint : boolean, objEnv : Object)
Sets environment variables used by this class (the controller for the JSX architecture)
Method Summary
jsx3.gui.Window
createAppWindow(strName : String)
Creates a new jsx3.gui.Window instance for this server.
void
deleteCookie(name : String, path : String, domain : String)
delete a cookie
void
call to shut down a server instance and free up resources used by the server (cache,dom,etc)
jsx3.app.Model
To implement jsx3.gui.Alerts interface.
jsx3.gui.Window
getAppWindow(strName : String)
Retrieves a previously created jsx3.gui.Window instance.
jsx3.gui.Block
Returns the body block for this server (JSXBODY)
jsx3.app.Cache
Returns the XML/XSL cache for this server
String
getCookie(name : String, bRaw : ?)
Returns the value for the Cookie with the given @name
jsx3.app.DOM
Returns the DOM for this server
jsx3.util.Locale
Returns the default locale of this server.
HTMLDocument
Returns the browser document object containing a particular JSX object.
String
getDynamicProperty(strPropName : String, strToken : String...)
Returns the value of the dynamic property @strPropName
String
getEnv(strEnvKey : String)
Returns the value of an environment setting of this server.
jsx3.app.Model
getJSX(strId : String)
Looks up a DOM node owned by this server by id or by name.
jsx3.app.Model
getJSXById(strId : String)
Looks up a DOM node owned by this server by id.
jsx3.app.Model
getJSXByName(strId : String)
Looks up a DOM node owned by this server by name.
jsx3.util.Locale
Returns the current locale of this server.
jsx3.app.Properties
Returns the dynamic properties registry for this server.
HTMLElement
Returns the browser DOM object where a particulat JSX object renders.
jsx3.gui.Block
Returns the root block for this server (JSXROOT)
Array<jsx3.app.Model>
Returns the list of objects that are children of the body object.
jsx3.app.Server
Deprecated.
jsx3.app.Settings
Returns the settings of this server/project per config.xml
jsx3.gui.WindowBar
Returns handle to a descendant taskbar belonging to this server instance (this is where JSXDialog instances will try to minimize to if it exists); returns null if none found; if no taskbar is found, dialogs are not minimized, but are 'window shaded'—like a Mac used to do
String
static String
Deprecated.
void
Invokes context-sensitive help as though the user had pressed the help hot key in the context of the DOM node objJSX.
jsx3.gui.Window
loadAppWindow(strSource : jsx3.xml.Entity | String, objResolver : jsx3.net.URIResolver)
Loads a new jsx3.gui.Window instance from a component file.
jsx3.xml.Document | jsx3.net.Service | null
loadInclude(strSrc : String | jsx3.net.URI, strId : String, strType : String, bReload : String)
Loads an external resource into this server instance.
jsx3.xml.Document | jsx3.net.Service | null
loadResource(strId : String)
Loads an application resource.
void
Paints this application and its default component into the application view port on the host HTML page.
jsx3.net.URI
relativizeURI(strURI : String | jsx3.net.URI, bRel : ?)
void
Reloads all resource files that are localized.
jsx3.net.URI
Resolves a URI that is referenced from a file in this server.
void
setCookie(name : String, value : String, expires : Date, path : String, domain : String, secure : boolean, bRaw : ?)
Sets a Cookie with the given name and value
void
setDimensions(left : int | Array, top : int, width : int, height : int)
set all four dimensions for a jsx3.Server instance, allowing the developer to adjust the width/height/left/width for the server.
void
setDynamicProperty(strPropName : String, vntValue : String)
updates a single dynamic style property; dynamic properties are used by jsx3.gui.Block objects that extend the astract class, jsx3.gui.Block;
void
Sets the locale of this server.
String
void
Removes a loaded JavaScript or CSS resource from the browser DOM.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.gui.Alerts
alert, configureAlert, confirm, prompt
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

Cache

jsx3.app.Cache Cache
Deprecated. Use Server.getCache()

DOM

jsx3.app.DOM DOM
Deprecated. Use Server.getDOM()

ENVIRONMENT

Object<String, String> ENVIRONMENT
Deprecated. Use Server.getEnv()

HELP

static String HELP
The subject of an event that instances of this class publish when a context help hot key is pressed in the context of a DOM node that has a help ID. The event has the following fields:
  • target - the server publishing the event.
  • model - the DOM node that received the key event.
  • helpid - the help ID of the nearest ancestor of model that defines a help ID.

INITED

static String INITED
The subject of an event that jsx3.app.Server publishes when an instance of this class is created. The target of the event object is the initialized server.

JSXBODY

jsx3.gui.Block JSXBODY
Deprecated. Use Server.getBodyBlock()

JSXROOT

jsx3.gui.Block JSXROOT
Deprecated. Use Server.getRootBlock()
Constructor Detail

init

void init(strAppPath : String, objGUI : HTMLElement, bPaint : boolean, objEnv : Object)
Sets environment variables used by this class (the controller for the JSX architecture)

Parameters:

strAppPathURL (either relative or absolute) for the application to load
objGUIthe browser element (body, div, span, td, etc) into which the GI application should load
bPaintfalse if null; if true, the application VIEW will immediately be generated.
objEnv
Method Detail

createAppWindow

jsx3.gui.Window createAppWindow(strName : String)
Creates a new jsx3.gui.Window instance for this server. A branch of the DOM of this application can be placed in this window in order to distribute the application across multiple browser windows.

Parameters:

strNamethe unique name of the window to create

Throws:

{jsx3.lang.IllegalArgumentException}if there already exists a window in this server by that name

Returns:

 

Since:

3.2

deleteCookie

void deleteCookie(name : String, path : String, domain : String)
delete a cookie

Parameters:

namename of the cookie
pathpath where the cookie is valid (default: path of calling document)
domaindomain where the cookie is valid (default: domain of calling document)

destroy

void destroy()
call to shut down a server instance and free up resources used by the server (cache,dom,etc)

getAlertsParent

jsx3.app.Model getAlertsParent()
To implement jsx3.gui.Alerts interface.

Returns:

the root block.  

Overrides:


getAppWindow

jsx3.gui.Window getAppWindow(strName : String)
Retrieves a previously created jsx3.gui.Window instance.

Parameters:

strNamethe unique name of the window to retrieve

Returns:

the window instance or null if no such window exists. 

Since:

3.2

getBodyBlock

jsx3.gui.Block getBodyBlock()
Returns the body block for this server (JSXBODY)

Returns:

 

getCache

jsx3.app.Cache getCache()
Returns the XML/XSL cache for this server

Returns:

 

getCookie

String getCookie(name : String, bRaw : ?)
Returns the value for the Cookie with the given @name

Parameters:

namename of the cookie
bRaw

Returns:

 

getDOM

jsx3.app.DOM getDOM()
Returns the DOM for this server

Returns:

 

getDefaultLocale

jsx3.util.Locale getDefaultLocale()
Returns the default locale of this server. This is configured with the default_locale configuration setting.

Returns:

 

Since:

3.2

getDocumentOf

HTMLDocument getDocumentOf(objJSX : jsx3.app.Model)
Returns the browser document object containing a particular JSX object. This method inspects whether the JSX object is a descendent of the root block of this server or one of its jsx3.gui.Window roots.

Parameters:

objJSX

Returns:

document object  

getDynamicProperty

String getDynamicProperty(strPropName : String, strToken : String...)
Returns the value of the dynamic property @strPropName

Parameters:

strPropNameid for this dynamic property among all properties
strTokenif present tokens such as {0}, {1}, {n} will be replaced with the nth element of this vararg array

Returns:

value of the property  

getEnv

String getEnv(strEnvKey : String)
Returns the value of an environment setting of this server. Valid keys correspond to deployment options and are (case-insensitive):
  • VERSION
  • APPPATH
  • ABSPATH
  • CAPTION
  • MODE
  • SYSTEM
  • NAMESPACE
  • CANCELERROR
  • CANCELRIGHTCLICK
  • BODYHOTKEYS
  • WIDTH
  • HEIGHT
  • LEFT
  • TOP
  • POSITION
  • OVERFLOW
  • UNICODE
  • EVENTSVERS

Parameters:

strEnvKeythe key of the environment value to return

Returns:

 

getJSX

jsx3.app.Model getJSX(strId : String)
Looks up a DOM node owned by this server by id or by name.

Parameters:

strIdeither the id (_jsxid) of the object or its name (jsxname)

Returns:

the JSX object or null if none found 

See Also:


getJSXById

jsx3.app.Model getJSXById(strId : String)
Looks up a DOM node owned by this server by id.

Parameters:

strIdthe id (_jsxid) of the object

Returns:

the JSX object or null if none found 

See Also:


getJSXByName

jsx3.app.Model getJSXByName(strId : String)
Looks up a DOM node owned by this server by name. If more than one such objects exist, only one is returned.

Parameters:

strIdthe name (jsxname) of the object

Returns:

the JSX object or null if none found 

See Also:


getLocale

jsx3.util.Locale getLocale()
Returns the current locale of this server. If the locale has been set explicitly with setLocale(), that locale is returned. Otherwise, getDefaultLocale() is consulted, and finally the system-wide locale.

Returns:

 

Since:

3.2

getProperties

jsx3.app.Properties getProperties()
Returns the dynamic properties registry for this server. The returned object contains the properties contained in all loaded resources of type 'jss' and 'ljss.' It also contains any properties loaded by the system or active add-ins.

Returns:

 

getRenderedOf

HTMLElement getRenderedOf(objJSX : jsx3.app.Model)
Returns the browser DOM object where a particulat JSX object renders. This method inspects the main root of this server as well as all of its jsx3.gui.Window roots.

Parameters:

objJSX

Returns:

DOM object  

getRootBlock

jsx3.gui.Block getRootBlock()
Returns the root block for this server (JSXROOT)

Returns:

 

getRootObjects

Array<jsx3.app.Model> getRootObjects()
Returns the list of objects that are children of the body object. These are the root objects in a serialization file and the root nodes in the Component Hierarchy palette.

Returns:

 

getServer

jsx3.app.Server getServer()
Deprecated.
Conforms to the EventDispatcher contract.

Returns:

this object. 

getSettings

jsx3.app.Settings getSettings()
Returns the settings of this server/project per config.xml

Returns:

 

getTaskBar

jsx3.gui.WindowBar getTaskBar(objJSX : jsx3.app.Model)
Returns handle to a descendant taskbar belonging to this server instance (this is where JSXDialog instances will try to minimize to if it exists); returns null if none found; if no taskbar is found, dialogs are not minimized, but are 'window shaded'—like a Mac used to do

Parameters:

objJSXif null, this.JSXROOT is assumed; otherwise the object in the DOM from which to start looking for a descendant taskbar (a jsx3.gui.WindowBar instance)

Returns:

 

getUriPrefix

String getUriPrefix()

Returns:

 

Overrides:

Since:

3.2

getVersion

static String getVersion()
Deprecated.
Returns version of the JSX runtime; separate versions are also available for GUI and Operational classes

Returns:

app version number (major (MM), minor (mm), and dot release (dd)) MM.mm.dd 

invokeHelp

void invokeHelp(objJSX : jsx3.app.Model)
Invokes context-sensitive help as though the user had pressed the help hot key in the context of the DOM node objJSX.

Parameters:

objJSX

Since:

3.5

See Also:


loadAppWindow

jsx3.gui.Window loadAppWindow(strSource : jsx3.xml.Entity | String, objResolver : jsx3.net.URIResolver)
Loads a new jsx3.gui.Window instance from a component file.

Parameters:

strSourceeither an XML document containing the window to load or the URL of the component to load.
objResolverIf this parameter is provided, strSource is resolved relative to it. Additionally, this resolver is stored as the URI resolver for this DOM node and its descendants.

Throws:

{jsx3.lang.Exception}if the loaded entity is not an instance of jsx3.gui.Window or if the name of window is not unique with respect to the already loaded windows

Returns:

 

Since:

3.2

loadInclude

jsx3.xml.Document | jsx3.net.Service | null loadInclude(strSrc : String | jsx3.net.URI, strId : String, strType : String, bReload : String)
Loads an external resource into this server instance. What this method does depends on the strType parameter.
  • script - Loads a JavaScript file asynchronously into the memory space of the page hosting this application; returns null.
  • css - Loads a CSS file asynchronously into the memory space of the page hosting this application; returns null.
  • xml or xsl - Loads an XML file synchronously into the XML cache of this application; returns the loaded jsx3.xml.Document instance.
  • jss or ljss - Loads a dynamic properties file or localized properties bundle synchronously into this application; returns null.
  • services - Loads and parses a mapping rules file synchronously; returns a new instance of jsx3.net.Service.

Parameters:

strSrcthe path to the resource.
strIdthe unique identifier of the resource. A resource loaded by this method may clobber a previously loaded resource of the same type and id.
strTypethe type of include, one of: css, jss, xml, xsl, script (for JavaScript), services (for mapping rules), or ljss.
bReloadif true, a JavaScript or CSS file is reloaded from the remote server without checking the local browser cache. Other types of resources are not affected by this parameter.

Throws:

{jsx3.lang.IllegalArgumentException}if strType in not a valid type.

Returns:

the return type depends on the strType parameter. See the method description. 

loadResource

jsx3.xml.Document | jsx3.net.Service | null loadResource(strId : String)
Loads an application resource. This method looks up a resource registered with this application by its id. The resource must be registered in the config.xml file of this application.

Parameters:

strIdunique identifier for the resource (its unique id as an application resource file).

Returns:

the return type depends on the type of resource. See the documentation for loadInclude() for more information. 

See Also:


paint

void paint(objXML : jsx3.xml.Document)
Paints this application and its default component into the application view port on the host HTML page. The system class loader calls this method once all the required resources of the application have loaded. The order of actions taken by this method is:
  1. Load the default component file
  2. Execute the onload script for the application
  3. Paint the default component in the view port

Parameters:

objXMLthe pre-loaded default component document.

relativizeURI

jsx3.net.URI relativizeURI(strURI : String | jsx3.net.URI, bRel : ?)

Parameters:

strURIthe URI to relativize.
bRel

Returns:

the relativized URI. 

Overrides:

Since:

3.2

reloadLocalizedResources

void reloadLocalizedResources()
Reloads all resource files that are localized. This method should be called after calling setLocale() for the server to render properly in the new locale.

Since:

3.2

resolveURI

jsx3.net.URI resolveURI(strURI : String | jsx3.net.URI)
Resolves a URI that is referenced from a file in this server. This method takes into account the changes in resource addressing between 3.1 and 3.2. For version 3.1, the URI is resolved as any URI in the system, using jsx3.resolveURI(). In version 3.2, the URI is taken as relative to the application folder. In particular, a relative URI will be resolved to a base of the application folder, an absolute URI will be unaffected.

Parameters:

strURIthe URI to resolve.

Returns:

the resolved URI. 

Overrides:

Since:

3.2

See Also:


setCookie

void setCookie(name : String, value : String, expires : Date, path : String, domain : String, secure : boolean, bRaw : ?)
Sets a Cookie with the given name and value

Parameters:

namename of the cookie
valuevalue of the cookie
expiresvalid jscript date object. for example: new Date("11:59:59 12-31-2004")
pathpath where the cookie is valid (default: path of calling document)
domaindomain where the cookie is valid (default: domain of calling document)
securevalid jscript date object. for example: new Date("11:59:59 12-31-2004")
bRaw

setDimensions

void setDimensions(left : int | Array, top : int, width : int, height : int)
set all four dimensions for a jsx3.Server instance, allowing the developer to adjust the width/height/left/width for the server. Must be called during/after the onload event for the server instance as it affects the VIEW for the server. Updates the absolutely positioned element that contains JSXROOT.

Parameters:

leftthe new left value or a JavaScript array containing all four new values (in pixels)
topthe new top value (in pixels)
widththe new width value (in pixels)
heightthe new height value (in pixels)

setDynamicProperty

void setDynamicProperty(strPropName : String, vntValue : String)
updates a single dynamic style property; dynamic properties are used by jsx3.gui.Block objects that extend the astract class, jsx3.gui.Block;

Parameters:

strPropNameid for this dynamic property among all properties
vntValuevalue of the property; if null, the property with the name, @strPropName will be removed

setLocale

void setLocale(objLocale : jsx3.util.Locale)
Sets the locale of this server.

Parameters:

objLocale

Since:

3.2

toString

String toString()

Returns:

 

Overrides:


unloadInclude

void unloadInclude(strId : String)
Removes a loaded JavaScript or CSS resource from the browser DOM.

Parameters:

strIdthe id used when loading the resource.

See Also:


jsx3.app

class Settings

Object
->jsx3.lang.Object
  ->jsx3.app.Settings

class Settings
extends jsx3.lang.Object
An object oriented interface onto the XML system settings format. Note that this class has no ability to save preferences to disk or other medium. However, the source XML data is returned by calling getNode() with no parameters.

Since:

3.0

Constructor Summary
void
The instance initializer.
Method Summary
String | Number | boolean | Array | Object
get(strKey : String...)
Returns a stored setting value.
jsx3.xml.Entity
getNode(strKey : String...)
Returns a stored setting value as the raw XML node.
void
remove(strKey : String...)
Removes a stored setting value.
void
set(strKey : String..., value : String | Number | boolean | Array | Object)
Sets a stored setting value.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objXML : jsx3.xml.Document)
The instance initializer. Creates a view onto the settings persisted on disk. All identical instances of this class are backed by the same XML source document.

Parameters:

objXMLthe underlying XML datasource.
Method Detail

get

String | Number | boolean | Array | Object get(strKey : String...)
Returns a stored setting value.

Parameters:

strKeythe setting key.

Returns:

the stored value.  

getNode

jsx3.xml.Entity getNode(strKey : String...)
Returns a stored setting value as the raw XML node.

Parameters:

strKeythe setting key.

Returns:

 

remove

void remove(strKey : String...)
Removes a stored setting value.

Parameters:

strKey

Since:

3.6

set

void set(strKey : String..., value : String | Number | boolean | Array | Object)
Sets a stored setting value.

Parameters:

strKey
valuethe value to store, map be string, number, boolean, array, or object (map)

Since:

3.6

jsx3.app

class UserSettings

Object
->jsx3.lang.Object
  ->jsx3.app.UserSettings

class UserSettings
extends jsx3.lang.Object
Read-Write per-User settings for a particular GI application (server).

This implementation stores settings in a browser cookie.

Since:

3.0

Field Summary
static int
static int
Constructor Summary
void
init(objServer : jsx3.app.Server, intPersistence : int)
The instance initializer.
Method Summary
void
Clears all settings of this user settings instance.
String | Number | boolean | Array | Object
get(strKey : String...)
Returns a stored setting value.
void
remove(strKey : String...)
Removes a stored setting value.
void
Persists the user settings.
void
set(strKey : String..., value : String | Number | boolean | Array | Object)
Sets a stored setting value.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

PERSIST_INDEFINITE

static final int PERSIST_INDEFINITE

PERSIST_SESSION

static final int PERSIST_SESSION
Constructor Detail

init

void init(objServer : jsx3.app.Server, intPersistence : int)
The instance initializer.

Parameters:

objServerthe app server.
intPersistencethe persistence code, defaults to PERSIST_INDEFINITE.
Method Detail

clear

void clear()
Clears all settings of this user settings instance. This implementation deletes the cookie.

get

String | Number | boolean | Array | Object get(strKey : String...)
Returns a stored setting value.

Parameters:

strKeythe setting key.

Returns:

the stored value.  

remove

void remove(strKey : String...)
Removes a stored setting value.

Parameters:

strKeythe key of the setting to remove.

save

void save()
Persists the user settings. Any modifications to this user settings instance will be lost if this method is not called.

set

void set(strKey : String..., value : String | Number | boolean | Array | Object)
Sets a stored setting value.

Parameters:

strKeythe setting key.
valuethe value to store.

package jsx3.chart

Various Charting related constants and utility functions.

Version:

1.1

Authors:

Jesse Costello-Good

Class Summary
jsx3.chart.AreaChart
An area chart.
jsx3.chart.AreaSeries
A data series for an area chart.
jsx3.chart.Axis
A base class for all types of axis.
jsx3.chart.BCChart
Superclass of bar and column chart.
jsx3.chart.BCSeries
Shared functionality between BarSeries and ColumnSeries.
jsx3.chart.BarChart
A bar chart.
jsx3.chart.BarSeries
The data series type for a jsx3.chart.BarChart.
jsx3.chart.BubbleSeries
A data series used for a jsx3.chart.BubbleChart.
jsx3.chart.CartesianChart
Base chart class for charts that render on a cartesian plane with x and y axes.
jsx3.chart.CategoryAxis
Axis type that displays a set of discrete values (categories).
jsx3.chart.Chart
The base class for all charts in this package.
jsx3.chart.ChartComponent
A base class for every logical component of a chart.
jsx3.chart.ChartLabel
A chart component to render a text box.
jsx3.chart.ColumnChart
A column chart.
jsx3.chart.ColumnSeries
The data series type for a jsx3.chart.ColumnChart.
jsx3.chart.GridLines
A chart component that renders a grid of lines and fills aligned with an x and y axis.
jsx3.chart.Legend
Chart component that renders a simple legend.
jsx3.chart.LineChart
A line chart.
jsx3.chart.LineSeries
A data series for a line chart.
jsx3.chart.LinearAxis
Type of axis that displays a linear range of values.
jsx3.chart.LogarithmicAxis
An axis that displays a range of values logarithmically (base^n and base^(n+1) occupy same visual space).
jsx3.chart.PieChart
A pie chart.
jsx3.chart.PieSeries
A data series for a pie chart.
jsx3.chart.PlotChart
An plot (scatter/point/bubble) chart.
jsx3.chart.PlotSeries
Class encapsulating behavior shared by PointSeries and BubbleSeries
jsx3.chart.PointRenderer
Objects that implement this interface may be used in Line/Area/Point/Bubble charts to render the points that appear at each datapoint.
jsx3.chart.PointSeries
A data series used for a jsx3.chart.PointChart.
jsx3.chart.RadialChart
Base class for radial charts (pie chart is only example so far).
jsx3.chart.Series
The base class for all data series classes.
Field Summary
static String
bottom/south quadrant
static String
left/west quadrant
static String
right/east quadrant
static String
top/north quadrant
Method Summary
static jsx3.vector.Fill
addGradient(fill : jsx3.vector.Fill, value : String)
Utility function, combines a vector fill and the property editor string format of a gradient
static Number
Utility function, converts a value to a Number
static boolean
Tests whether an object is an Axis that displays set of discreet categories
static boolean
Tests whether an object is an Axis that displays a range of number values
static Array
Utility function, parses the property editor string format of a gradient into its constituent parts
static Array
splitBox(left : int, top : int, width : int, height : int, placement : String, w : int, h : int)
Splits a rectangular box in two pieces.
Field Detail

QBOTTOM

static final String QBOTTOM
bottom/south quadrant

QLEFT

static final String QLEFT
left/west quadrant

QRIGHT

static final String QRIGHT
right/east quadrant

QTOP

static final String QTOP
top/north quadrant
Method Detail

addGradient

static jsx3.vector.Fill addGradient(fill : jsx3.vector.Fill, value : String)
Utility function, combines a vector fill and the property editor string format of a gradient

Parameters:

fillthe base fill
valuethe gradient in the form "color [angle [alpha [colors ...]]]"

Returns:

 

asNumber

static Number asNumber(v : Object)
Utility function, converts a value to a Number

Parameters:

v

Returns:

 

isCategoryAxis

static boolean isCategoryAxis(obj : Object)
Tests whether an object is an Axis that displays set of discreet categories

Parameters:

obj

Returns:

 

isValueAxis

static boolean isValueAxis(obj : Object)
Tests whether an object is an Axis that displays a range of number values

Parameters:

obj

Returns:

 

parseGradient

static Array parseGradient(value : String)
Utility function, parses the property editor string format of a gradient into its constituent parts

Parameters:

valuethe gradient in the form "color [angle [alpha [colors ...]]]"

Returns:

[color,angle,alpha,colors]  

splitBox

static Array splitBox(left : int, top : int, width : int, height : int, placement : String, w : int, h : int)
Splits a rectangular box in two pieces.

Parameters:

leftthe left value of the box to split
topthe top value of the box to split
widththe width value of the box to split
heightthe height value of the box to split
placement{top,left,right,bottom} where to place the first sub-box
wthe desired width of the first sub-box
hthe desired height of the first sub-box

Returns:

[[l1,t1,w1,h1],[l2,t2,w2,h2]]  

jsx3.chart

class AreaChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.AreaChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class AreaChart
extends jsx3.chart.CartesianChart
An area chart.

Series: AreaSeries only.
Axes: Y axis must be value axis, X axis can be value or category axis

The 'type' my be 'overlay', 'stacked', or 'stacked100', which correspond to the basic Excel-like variations of an area chart.

Field Summary
static String
static String
static String
Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
String
Returns the type field, corresponds to the variation of area chart, one of {'overlay','stacked','stacked100'}.
static String
Deprecated.
void
getXRange(series : ?)
Returns the range of x values, used when x axis is value axis.
void
getYRange(series : ?)
Returns the range of y values, considers chart type.
void
setType(type : String)
Sets the type field.
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

TYPE_OVERLAY

static final String TYPE_OVERLAY

TYPE_STACKED

static final String TYPE_STACKED

TYPE_STACKED100

static final String TYPE_STACKED100
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getType

String getType()
Returns the type field, corresponds to the variation of area chart, one of {'overlay','stacked','stacked100'}.

Returns:

type  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXRange

void getXRange(series : ?)
Returns the range of x values, used when x axis is value axis.

Parameters:

series

Overrides:


getYRange

void getYRange(series : ?)
Returns the range of y values, considers chart type.

Parameters:

series

Overrides:


setType

void setType(type : String)
Sets the type field.

Parameters:

typethe new value for type, one of {'overlay','stacked','stacked100'}

jsx3.chart

class AreaSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.AreaSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class AreaSeries
extends jsx3.chart.Series
A data series for an area chart. An area series draws a solid polygon between the x-axis and a line defined by the data provider, or between a minimum line and a maximum line both defined by the data provider. An area series has the following properties:
xField
the attribute of a record to use as the x-coordinate of points defining the min and max line of the area, required if the x-axis is a value axis
yField
the attribute of a record to use as the y-coordinate of points defining the max line of the area, required
minField
the attribute of a record to use as the y-coordinate of points defining the min line of the area, optional
form
defines how the area is drawn, one of {'segment','step','reverseStep'}, defaults to 'segment'
The area series can also be painted with points at each data point. See LineSeries for a description of the relevant fields.

Field Summary
static String
static String
static String
Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
String
Returns the form field.
String
Returns the minField field.
Number
Returns the minimum y-coordinate of a data point in this series for the given record.
String
Returns the pointFill field.
String
Returns the pointGradient field.
int
Returns the pointRadius field.
jsx3.chart.PointRenderer
Returns the pointRenderer field.
String
Returns the pointStroke field.
static String
Deprecated.
String
Returns the xField field.
Number
Returns the x-coordinate of a data point in this series for the given record.
String
Returns the yField field.
Number
Returns the y-coordinate of a data point in this series for the given record.
void
setForm(form : String)
Sets the form field, checks for valid value.
void
setMinField(minField : String)
Sets the minField field.
void
setPointFill(pointFill : String)
Sets the pointFill field, string representation of vector fill.
void
setPointGradient(pointGradient : String)
Sets the pointGradient field, string representation of vector fill gradient.
void
setPointRadius(pointRadius : int)
Sets the pointRadius field.
void
setPointRenderer(pointRenderer : String)
Sets the pointRenderer field.
void
setPointStroke(pointStroke : String)
Sets the pointStroke field, string representation of VectorStroke.
void
setXField(xField : String)
Sets the xField field.
void
setYField(yField : String)
Sets the yField field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

FORM_REVSTEP

static final String FORM_REVSTEP

FORM_SEGMENT

static final String FORM_SEGMENT

FORM_STEP

static final String FORM_STEP
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getForm

String getForm()
Returns the form field.

Returns:

form  

getMinField

String getMinField()
Returns the minField field.

Returns:

minField  

getMinValue

Number getMinValue(record : jsx3.xml.Entity)
Returns the minimum y-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getPointFill

String getPointFill()
Returns the pointFill field.

Returns:

pointFill  

getPointGradient

String getPointGradient()
Returns the pointGradient field.

Returns:

pointGradient  

getPointRadius

int getPointRadius()
Returns the pointRadius field.

Returns:

pointRadius  

getPointRenderer

jsx3.chart.PointRenderer getPointRenderer()
Returns the pointRenderer field.

Returns:

pointRenderer  

getPointStroke

String getPointStroke()
Returns the pointStroke field.

Returns:

pointStroke  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXField

String getXField()
Returns the xField field.

Returns:

xField  

getXValue

Number getXValue(record : jsx3.xml.Entity)
Returns the x-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getYField

String getYField()
Returns the yField field.

Returns:

yField  

getYValue

Number getYValue(record : jsx3.xml.Entity)
Returns the y-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

setForm

void setForm(form : String)
Sets the form field, checks for valid value.

Parameters:

formthe new value for form, one of {'segment','step','reverseStep'}

setMinField

void setMinField(minField : String)
Sets the minField field.

Parameters:

minFieldthe new value for minField

setPointFill

void setPointFill(pointFill : String)
Sets the pointFill field, string representation of vector fill.

Parameters:

pointFillthe new value for pointFill

setPointGradient

void setPointGradient(pointGradient : String)
Sets the pointGradient field, string representation of vector fill gradient.

Parameters:

pointGradientthe new value for pointGradient

setPointRadius

void setPointRadius(pointRadius : int)
Sets the pointRadius field.

Parameters:

pointRadiusthe new value for pointRadius

setPointRenderer

void setPointRenderer(pointRenderer : String)
Sets the pointRenderer field.

Parameters:

pointRendererthe new value for pointRenderer, should eval to an object that implements the renderer interface

setPointStroke

void setPointStroke(pointStroke : String)
Sets the pointStroke field, string representation of VectorStroke.

Parameters:

pointStrokethe new value for pointStroke

setXField

void setXField(xField : String)
Sets the xField field.

Parameters:

xFieldthe new value for xField

setYField

void setYField(yField : String)
Sets the yField field.

Parameters:

yFieldthe new value for yField

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class Axis

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Axis

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.CategoryAxis, jsx3.chart.LinearAxis, jsx3.chart.LogarithmicAxis

class Axis
extends jsx3.chart.ChartComponent
A base class for all types of axis. Provides all the common properties as well as all rendering logic. Rendering relies on template methods implemented in concrete subclasses.

An axis renders in the following location based on its horizontal and primary properties:
  horizontal x primary   -> bottom
  vertical x primary     -> left
  horizontal x secondary -> top
  vertical x secondary   -> right

Field Summary
static String
static String
static String
static String
static String
static String
static String
Constructor Summary
void
init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.
Method Summary
String
Returns the axisStroke field, string representation of the VectorStroke used to draw the line of the axis.
jsx3.chart.ChartLabel
Returns the optional jsx3.chart.ChartLabel child.
int
Returns the display width, the maximum amount of space perpendicular to the axis and outside of the data area that the ticks and labels may occupy (doesn't include area given to axis title).
boolean
Returns the horizontal field, whether this is an x axis, otherwise it is a y axis.
String
Returns the labelClass field, the CSS class used to render major tick labels.
String | Number
Returns the labelColor field, the RGB color value of the label font; note that this is the only way to set the color of the text, using a CSS style attribute will have no effect.
Function
Returns the labelFunction field.
int
Returns the labelGap field, the pixel gap between the tick lines and the labels.
String
Returns the labelStyle field, the CSS style attribute used to render major tick labels.
int
Returns the minorTickDivisions field, number of minor tick divisions between major ticks; the number of minor ticks drawn will be this number minus 1.
int
Returns the minorTickLength field, the length in pixels of the minor tick (if tickPlacement is "cross" the length will actually be twice this.
String
Returns the minorTickPlacement field, where to place the minor ticks.
String
Returns the minorTickStroke field, string representation of VectorStroke used to draw minor ticks.
jsx3.chart.Axis
Returns the opposing axis.
boolean
Returns the showAxis field, whether to show the line along the axis.
boolean
Returns the showLabels field, whether to show major tick labels.
int
Returns the tickLength field, the length in pixels of the major tick (if tickPlacement is "cross" the length will actually be twice this.
String
Returns the tickPlacement field, where to place the major ticks.
String
Returns the tickStroke field, string representation of VectorStroke used to draw major ticks.
static String
Deprecated.
static String
formats labels as a percent, ie "50%"
static String
scientific(v : Number, signif : int)
formats labels in scientific notation, ie "5e2"
void
setAxisStroke(axisStroke : String)
Sets the axisStroke field.
void
setDisplayWidth(displayWidth : int)
Sets the displayWidth field.
void
setHorizontal(horizontal : boolean)
Sets the horizontal field.
void
setLabelClass(labelClass : String)
Sets the labelClass field.
void
setLabelColor(labelColor : String | Number)
Sets the labelColor field.
void
setLabelFunction(labelFunction : String | Function)
Sets the labelFunction field, allows for formatting and transformation of a major tick label.
void
setLabelGap(labelGap : int)
Sets the labelGap field.
void
setLabelPlacement(labelPlacement : String)
Sets the labelPlacement field, checks for invalid values.
void
setLabelStyle(labelStyle : String)
Sets the labelStyle field.
void
setMinorTickDivisions(minorTickDivisions : int)
Sets the minorTickDivisions field.
void
setMinorTickLength(minorTickLength : int)
Sets the minorTickLength field.
void
setMinorTickPlacement(minorTickPlacement : String)
Sets the minorTickPlacement field.
void
setMinorTickStroke(minorTickStroke : String)
Sets the minorTickStroke field.
void
setShowAxis(showAxis : boolean)
Sets the showAxis field.
void
setShowLabels(showLabels : boolean)
Sets the showLabels field.
void
setTickLength(tickLength : int)
Sets the tickLength field.
void
setTickPlacement(tickPlacement : String)
Sets the tickPlacement field.
void
setTickStroke(tickStroke : String)
Sets the tickStroke field.
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

LABEL_AXIS

static final String LABEL_AXIS

LABEL_HIGH

static final String LABEL_HIGH

LABEL_LOW

static final String LABEL_LOW

TICK_CROSS

static final String TICK_CROSS

TICK_INSIDE

static final String TICK_INSIDE

TICK_NONE

static final String TICK_NONE

TICK_OUTSIDE

static final String TICK_OUTSIDE
Constructor Detail

init

void init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.

Parameters:

namethe GI name of the instance
horizontalwhether this axis is horizontal (x), otherwise it's vertical (y)
primarywhether this axis is primary, otherwise it's secondary
Method Detail

getAxisStroke

String getAxisStroke()
Returns the axisStroke field, string representation of the VectorStroke used to draw the line of the axis.

Returns:

axisStroke  

getAxisTitle

jsx3.chart.ChartLabel getAxisTitle()
Returns the optional jsx3.chart.ChartLabel child.

Returns:

 

getDisplayWidth

int getDisplayWidth()
Returns the display width, the maximum amount of space perpendicular to the axis and outside of the data area that the ticks and labels may occupy (doesn't include area given to axis title).

Returns:

displayWidth  

getHorizontal

boolean getHorizontal()
Returns the horizontal field, whether this is an x axis, otherwise it is a y axis.

Returns:

horizontal  

getLabelClass

String getLabelClass()
Returns the labelClass field, the CSS class used to render major tick labels.

Returns:

labelClass  

getLabelColor

String | Number getLabelColor()
Returns the labelColor field, the RGB color value of the label font; note that this is the only way to set the color of the text, using a CSS style attribute will have no effect.

Returns:

labelColor  

getLabelFunction

Function getLabelFunction()
Returns the labelFunction field.

Returns:

labelFunction  

getLabelGap

int getLabelGap()
Returns the labelGap field, the pixel gap between the tick lines and the labels.

Returns:

labelGap  

getLabelStyle

String getLabelStyle()
Returns the labelStyle field, the CSS style attribute used to render major tick labels.

Returns:

labelStyle  

getMinorTickDivisions

int getMinorTickDivisions()
Returns the minorTickDivisions field, number of minor tick divisions between major ticks; the number of minor ticks drawn will be this number minus 1.

Returns:

minorTickDivisions  

getMinorTickLength

int getMinorTickLength()
Returns the minorTickLength field, the length in pixels of the minor tick (if tickPlacement is "cross" the length will actually be twice this.

Returns:

minorTickLength  

getMinorTickPlacement

String getMinorTickPlacement()
Returns the minorTickPlacement field, where to place the minor ticks.

Returns:

minorTickPlacement, one of {'none','inside','outside','cross'}  

getMinorTickStroke

String getMinorTickStroke()
Returns the minorTickStroke field, string representation of VectorStroke used to draw minor ticks.

Returns:

minorTickStroke  

getOpposingAxis

jsx3.chart.Axis getOpposingAxis()
Returns the opposing axis.

Returns:

 

getShowAxis

boolean getShowAxis()
Returns the showAxis field, whether to show the line along the axis.

Returns:

showAxis  

getShowLabels

boolean getShowLabels()
Returns the showLabels field, whether to show major tick labels.

Returns:

showLabels  

getTickLength

int getTickLength()
Returns the tickLength field, the length in pixels of the major tick (if tickPlacement is "cross" the length will actually be twice this.

Returns:

tickLength  

getTickPlacement

String getTickPlacement()
Returns the tickPlacement field, where to place the major ticks.

Returns:

tickPlacement, one of {'none','inside','outside','cross'}  

getTickStroke

String getTickStroke()
Returns the tickStroke field, string representation of VectorStroke used to draw major ticks.

Returns:

tickStroke  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

percent

static String percent(v : Number)
formats labels as a percent, ie "50%"

Parameters:

v

Returns:

 

scientific

static String scientific(v : Number, signif : int)
formats labels in scientific notation, ie "5e2"

Parameters:

v
signif

Returns:

 

setAxisStroke

void setAxisStroke(axisStroke : String)
Sets the axisStroke field.

Parameters:

axisStrokethe new value for axisStroke

setDisplayWidth

void setDisplayWidth(displayWidth : int)
Sets the displayWidth field.

Parameters:

displayWidththe new value for displayWidth

setHorizontal

void setHorizontal(horizontal : boolean)
Sets the horizontal field.

Parameters:

horizontalthe new value for horizontal

setLabelClass

void setLabelClass(labelClass : String)
Sets the labelClass field.

Parameters:

labelClassthe new value for labelClass

setLabelColor

void setLabelColor(labelColor : String | Number)
Sets the labelColor field.

Parameters:

labelColorthe new value for labelColor

setLabelFunction

void setLabelFunction(labelFunction : String | Function)
Sets the labelFunction field, allows for formatting and transformation of a major tick label. The function will be applied to this object when called. Note that passing a function reference to this method will prevent the value from being persisted if this object is serialized.

Parameters:

labelFunctionthe new value for labelFunction, a function with the signature function(value : Number|String) : String.

setLabelGap

void setLabelGap(labelGap : int)
Sets the labelGap field.

Parameters:

labelGapthe new value for labelGap

setLabelPlacement

void setLabelPlacement(labelPlacement : String)
Sets the labelPlacement field, checks for invalid values.

Parameters:

labelPlacementthe new value for labelPlacement, one of {'axis','high','low'}

setLabelStyle

void setLabelStyle(labelStyle : String)
Sets the labelStyle field.

Parameters:

labelStylethe new value for labelStyle

setMinorTickDivisions

void setMinorTickDivisions(minorTickDivisions : int)
Sets the minorTickDivisions field.

Parameters:

minorTickDivisionsthe new value for minorTickDivisions

setMinorTickLength

void setMinorTickLength(minorTickLength : int)
Sets the minorTickLength field.

Parameters:

minorTickLengththe new value for minorTickLength

setMinorTickPlacement

void setMinorTickPlacement(minorTickPlacement : String)
Sets the minorTickPlacement field.

Parameters:

minorTickPlacementthe new value for minorTickPlacement, one of {'none','inside','outside','cross'}

setMinorTickStroke

void setMinorTickStroke(minorTickStroke : String)
Sets the minorTickStroke field.

Parameters:

minorTickStrokethe new value for minorTickStroke

setShowAxis

void setShowAxis(showAxis : boolean)
Sets the showAxis field.

Parameters:

showAxisthe new value for showAxis

setShowLabels

void setShowLabels(showLabels : boolean)
Sets the showLabels field.

Parameters:

showLabelsthe new value for showLabels

setTickLength

void setTickLength(tickLength : int)
Sets the tickLength field.

Parameters:

tickLengththe new value for tickLength

setTickPlacement

void setTickPlacement(tickPlacement : String)
Sets the tickPlacement field.

Parameters:

tickPlacementthe new value for tickPlacement, one of {'none','inside','outside','cross'}

setTickStroke

void setTickStroke(tickStroke : String)
Sets the tickStroke field.

Parameters:

tickStrokethe new value for tickStroke

jsx3.chart

class BCChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.BCChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

Direct Known Subclasses:

jsx3.chart.BarChart, jsx3.chart.ColumnChart

abstract class BCChart
extends jsx3.chart.CartesianChart
Superclass of bar and column chart. Contains all the common functionality, provides template methods to the subclasses so that they can render horizontal bars or vertical columns.

Basically abstracts a bar/column chart into a chart with a parallel dimension and a normal dimension. The parallel dimension is the dimension in which the rows/columns extend.

Field Summary
static String
static String
static String
Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
float
Returns the categoryCoverage field, the ratio of the range of a category that is covered by bars/columns.
float
Returns the seriesOverlap field, the ratio of a column width/row height that a column/row overlaps with the adjacent column/row.
String
Returns the type field, corresponds to the variation of chart, one of {'clustered','stacked','stacked100'}.
static String
Deprecated.
void
setCategoryCoverage(categoryCoverage : float)
Sets the categoryCoverage field.
void
setSeriesOverlap(seriesOverlap : float)
Sets the seriesOverlap field.
void
setType(type : String)
Sets the type field.
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis, getXRange, getYRange
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

TYPE_CLUSTERED

static final String TYPE_CLUSTERED

TYPE_STACKED

static final String TYPE_STACKED

TYPE_STACKED100

static final String TYPE_STACKED100
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getCategoryCoverage

float getCategoryCoverage()
Returns the categoryCoverage field, the ratio of the range of a category that is covered by bars/columns.

Returns:

categoryCoverage  

getSeriesOverlap

float getSeriesOverlap()
Returns the seriesOverlap field, the ratio of a column width/row height that a column/row overlaps with the adjacent column/row.

Returns:

seriesOverlap  

getType

String getType()
Returns the type field, corresponds to the variation of chart, one of {'clustered','stacked','stacked100'}.

Returns:

type  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setCategoryCoverage

void setCategoryCoverage(categoryCoverage : float)
Sets the categoryCoverage field.

Parameters:

categoryCoveragethe new value for categoryCoverage, between 0 and 1

setSeriesOverlap

void setSeriesOverlap(seriesOverlap : float)
Sets the seriesOverlap field.

Parameters:

seriesOverlapthe new value for seriesOverlap, usually between -0.5 and 0.5

setType

void setType(type : String)
Sets the type field.

Parameters:

typethe new value for type, one of {'clustered','stacked','stacked100'}

jsx3.chart

class BCSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.BCSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.BarSeries, jsx3.chart.ColumnSeries

class BCSeries
extends jsx3.chart.Series
Shared functionality between BarSeries and ColumnSeries.

Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
String
Returns the minField field.
Number
Returns the minimum value (x or y) of a data point in this series for the given record.
static String
Deprecated.
String
Returns the xField field.
Number
Returns the x-coordinate of a data point in this series for the given record.
String
Returns the yField field.
Number
Returns the y-coordinate of a data point in this series for the given record.
void
setMinField(minField : String)
Sets the minField field.
void
setXField(xField : String)
Sets the xField field.
void
setYField(yField : String)
Sets the yField field.
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getMinField

String getMinField()
Returns the minField field.

Returns:

minField  

getMinValue

Number getMinValue(record : jsx3.xml.Entity)
Returns the minimum value (x or y) of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXField

String getXField()
Returns the xField field.

Returns:

xField  

getXValue

Number getXValue(record : jsx3.xml.Entity)
Returns the x-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getYField

String getYField()
Returns the yField field.

Returns:

yField  

getYValue

Number getYValue(record : jsx3.xml.Entity)
Returns the y-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

setMinField

void setMinField(minField : String)
Sets the minField field.

Parameters:

minFieldthe new value for minField

setXField

void setXField(xField : String)
Sets the xField field.

Parameters:

xFieldthe new value for xField

setYField

void setYField(yField : String)
Sets the yField field.

Parameters:

yFieldthe new value for yField

jsx3.chart

class BarChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.BCChart
                ->jsx3.chart.BarChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class BarChart
extends jsx3.chart.BCChart
A bar chart.

Series: BarSeries only.
Axes: X axis must be value axis, Y axis can be value or category axis

The 'type' my be 'clustered', 'stacked', or 'stacked100', which correspond to the basic Excel-like variations of a bar chart.

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
Array<Number>
getXRange(series : ?)
Array<Number>
getYRange(series : ?)
Methods Inherited From jsx3.chart.BCChart
getCategoryCoverage, getSeriesOverlap, getType, setCategoryCoverage, setSeriesOverlap, setType
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getXRange

Array<Number> getXRange(series : ?)

Parameters:

series

Returns:

[min, max].  

Overrides:


getYRange

Array<Number> getYRange(series : ?)

Parameters:

series

Returns:

[min, max].  

Overrides:


jsx3.chart

class BarSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.BCSeries
              ->jsx3.chart.BarSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class BarSeries
extends jsx3.chart.BCSeries
The data series type for a jsx3.chart.BarChart. Draws horizontal bars between the y axis and an x value determined by the data provider, or between two x values determined by the data provider. A bar series has the following fields:
xField
the attribute of a record to use as the horizontal extent of the bar, required
yField
the attribute of a record to use as the vertical midpoint of the bar, required if the y axis of the chart is a value axis
minField
the attribute of a record to use as the minimum horizontal extent of the bar, optional

Field Summary
static int
Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
int
Returns the barHeight field.
void
setBarHeight(barHeight : int)
Sets the barHeight field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.BCSeries
getMinField, getMinValue, getXField, getXValue, getYField, getYValue, setMinField, setXField, setYField
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_BARHEIGHT

static int DEFAULT_BARHEIGHT
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getBarHeight

int getBarHeight()
Returns the barHeight field.

Returns:

barHeight  

setBarHeight

void setBarHeight(barHeight : int)
Sets the barHeight field.

Parameters:

barHeightthe new value for barHeight

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class BubbleSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.PlotSeries
              ->jsx3.chart.BubbleSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class BubbleSeries
extends jsx3.chart.PlotSeries
A data series used for a jsx3.chart.BubbleChart. A bubble series has the following fields: xField - the attribute of a record to use as the x-coordinate of points in the series, required yField - the attribute of a record to use as the y-coordinate of points in the series, required magnitudeField - the attribute of a record to use as the magnitude of points in the series, required pointRenderer - string that evals to an object that implements the renderer interface, optional

Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
String
Returns the magnitudeField field.
Number
Returns the magnitude of a data point in this series for the given record.
void
setMagnitudeField(magnitudeField : String)
Sets the magnitudeField field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.PlotSeries
getLegendRenderer, getRenderer, getXField, getXValue, getYField, getYValue, setRenderer, setXField, setYField
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getMagnitudeField

String getMagnitudeField()
Returns the magnitudeField field.

Returns:

magnitudeField  

getMagnitudeValue

Number getMagnitudeValue(record : jsx3.xml.Entity)
Returns the magnitude of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

setMagnitudeField

void setMagnitudeField(magnitudeField : String)
Sets the magnitudeField field.

Parameters:

magnitudeFieldthe new value for magnitudeField

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class CartesianChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

Direct Known Subclasses:

jsx3.chart.AreaChart, jsx3.chart.BCChart, jsx3.chart.LineChart, jsx3.chart.PlotChart

abstract class CartesianChart
extends jsx3.chart.Chart
Base chart class for charts that render on a cartesian plane with x and y axes. Currently only supports primary x and y axes, even though there are methods pertaining to secondary axes.

Cartesian charts can have the following additional children:
  1. {0,n} GridLines, will render lines aligned with the axes below or above the data series
  2. {2,n} Axis, required to define the coordinate space of the cartesian plane

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
Array<jsx3.chart.GridLines>
Returns the array of children GridLines instances.
jsx3.chart.Axis
Returns the primary x axis, if any.
jsx3.chart.Axis
Returns the primary y axis, if any.
Array<Number>
Returns the range for axis, delegates to getXRange() or getYRange().
static String
Deprecated.
abstract Array<Number>
Returns the range of x values in the data provider, subclasses must implement.
abstract Array<Number>
Returns the range of y values in the data provider, subclasses must implement.
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getGridLines

Array<jsx3.chart.GridLines> getGridLines()
Returns the array of children GridLines instances.

Returns:

gridLines  

getPrimaryXAxis

jsx3.chart.Axis getPrimaryXAxis()
Returns the primary x axis, if any.

Returns:

primaryXAxis  

getPrimaryYAxis

jsx3.chart.Axis getPrimaryYAxis()
Returns the primary y axis, if any.

Returns:

primaryYAxis  

getRangeForAxis

Array<Number> getRangeForAxis(axis : jsx3.chart.Axis)
Returns the range for axis, delegates to getXRange() or getYRange().

Parameters:

axis

Returns:

[min,max] or null if no range can be found  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXRange

abstract Array<Number> getXRange(series : Array<jsx3.chart.Series>)
Returns the range of x values in the data provider, subclasses must implement.

Parameters:

seriesthe series to consider

Returns:

[min,max] or null if no range can be found  

getYRange

abstract Array<Number> getYRange(series : Array<jsx3.chart.Series>)
Returns the range of y values in the data provider, subclasses must implement.

Parameters:

seriesthe series to consider

Returns:

[min,max] or null if no range can be found  

jsx3.chart

class CategoryAxis

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Axis
            ->jsx3.chart.CategoryAxis

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class CategoryAxis
extends jsx3.chart.Axis
Axis type that displays a set of discrete values (categories). Usually a category corresponds to a record in the chart's data provider.

Field Summary
static String
static String
Constructor Summary
void
init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.
Method Summary
String
Returns the categoryField field, the attribute of records from the data provider that contains the category name (this value can still be transformed by Axis's 'labelFunction' field).
float
Returns the paddingHigh field, the number of category widths to pad the end of the axis with.
float
Returns the paddingLow field, the number of category widths to pad the beginning of the axis with.
String
Returns the tickAlignment field, if 'between' then the midpoint of the category is between two major ticks, otherwise if 'aligned' then the midpoint of the category is aligned with a major tick.
static String
Deprecated.
void
setCategoryField(categoryField : String)
Sets the categoryField field.
void
setPaddingHigh(paddingHigh : float)
Sets the paddingHigh field.
void
setPaddingLow(paddingLow : float)
Sets the paddingLow field.
void
setTickAlignment(tickAlignment : String)
Sets the tickAlignment field.
Methods Inherited From jsx3.chart.Axis
getAxisStroke, getAxisTitle, getDisplayWidth, getHorizontal, getLabelClass, getLabelColor, getLabelFunction, getLabelGap, getLabelStyle, getMinorTickDivisions, getMinorTickLength, getMinorTickPlacement, getMinorTickStroke, getOpposingAxis, getShowAxis, getShowLabels, getTickLength, getTickPlacement, getTickStroke, setAxisStroke, setDisplayWidth, setHorizontal, setLabelClass, setLabelColor, setLabelFunction, setLabelGap, setLabelPlacement, setLabelStyle, setMinorTickDivisions, setMinorTickLength, setMinorTickPlacement, setMinorTickStroke, setShowAxis, setShowLabels, setTickLength, setTickPlacement, setTickStroke
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

TICKS_ALIGNED

static final String TICKS_ALIGNED

TICKS_BETWEEN

static final String TICKS_BETWEEN
Constructor Detail

init

void init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.

Parameters:

namethe GI name of the instance
horizontalwhether this axis is horizontal (x), otherwise it's vertical (y)
primarywhether this axis is primary, otherwise it's secondary
Method Detail

getCategoryField

String getCategoryField()
Returns the categoryField field, the attribute of records from the data provider that contains the category name (this value can still be transformed by Axis's 'labelFunction' field).

Returns:

categoryField  

getPaddingHigh

float getPaddingHigh()
Returns the paddingHigh field, the number of category widths to pad the end of the axis with.

Returns:

paddingHigh  

getPaddingLow

float getPaddingLow()
Returns the paddingLow field, the number of category widths to pad the beginning of the axis with.

Returns:

paddingLow  

getTickAlignment

String getTickAlignment()
Returns the tickAlignment field, if 'between' then the midpoint of the category is between two major ticks, otherwise if 'aligned' then the midpoint of the category is aligned with a major tick.

Returns:

tickAlignment, one of {'aligned','between'}  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setCategoryField

void setCategoryField(categoryField : String)
Sets the categoryField field.

Parameters:

categoryFieldthe new value for categoryField

setPaddingHigh

void setPaddingHigh(paddingHigh : float)
Sets the paddingHigh field.

Parameters:

paddingHighthe new value for paddingHigh

setPaddingLow

void setPaddingLow(paddingLow : float)
Sets the paddingLow field.

Parameters:

paddingLowthe new value for paddingLow

setTickAlignment

void setTickAlignment(tickAlignment : String)
Sets the tickAlignment field.

Parameters:

tickAlignmentthe new value for tickAlignment, one of {'aligned','between'}

jsx3.chart

class Chart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

Direct Known Subclasses:

jsx3.chart.CartesianChart, jsx3.chart.RadialChart

class Chart
extends jsx3.vector.Block
The base class for all charts in this package. Encapsulates common functionality shared by all charts.

In general, a chart is responsible for managing its children components and handling any coordination between them. A chart always manages the layout of its children.

All charts can have the following children:

Field Summary
static Array<jsx3.vector.Fill>
The default fill colors for series and categories whose fills are not specified.
Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
float
Returns the alpha field, the opacity to render the chart's background.
float
Returns the borderAlpha field, the opacity to render the chart's border.
String | Number
Returns the borderColor field, the RGB color to render the chart's border.
int
Returns the borderWidth field, the pixel width of the chart's border.
jsx3.chart.ChartLabel
Find the first jsx3.chart.ChartLabel child
String
Returns the dataPadding field, the CSS padding value that determines the padding around the data area, ie "10" or "5 0 5 0".
jsx3.chart.Legend
Find the first Legend child
int
in general the chart legend renders one entry for every series in the chart, override this method to show categories in the legend
String
Returns the legendPlacement field, the quadrant in which to place the legend.
Array<jsx3.chart.Series>
Returns the list of Series children.
int
Returns the index of a series in the list of series children.
String
Returns the titlePlacement field, the quadrant in which to place the title.
static String
Deprecated.
void
Note that this method is very expensive because it causes the entire chart to be redrawn.
void
setAlpha(alpha : float)
Sets the alpha field.
void
setBorderAlpha(borderAlpha : float)
Sets the borderAlpha field.
void
setBorderColor(borderColor : String | Number)
Sets the borderColor field.
void
setBorderWidth(borderWidth : int)
Sets the borderWidth field.
void
setDataPadding(dataPadding : String)
Sets the dataPadding field.
void
setLegendPlacement(legendPlacement : String)
Sets the legendPlacement field.
void
setTitlePlacement(titlePlacement : String)
Sets the titlePlacement field.
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_FILLS

static Array<jsx3.vector.Fill> DEFAULT_FILLS
The default fill colors for series and categories whose fills are not specified.
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getAlpha

float getAlpha()
Returns the alpha field, the opacity to render the chart's background.

Returns:

alpha  

getBorderAlpha

float getBorderAlpha()
Returns the borderAlpha field, the opacity to render the chart's border.

Returns:

borderAlpha  

getBorderColor

String | Number getBorderColor()
Returns the borderColor field, the RGB color to render the chart's border.

Returns:

borderColor  

getBorderWidth

int getBorderWidth()
Returns the borderWidth field, the pixel width of the chart's border.

Returns:

borderWidth  

getChartTitle

jsx3.chart.ChartLabel getChartTitle()
Find the first jsx3.chart.ChartLabel child

Returns:

 

getDataPadding

String getDataPadding()
Returns the dataPadding field, the CSS padding value that determines the padding around the data area, ie "10" or "5 0 5 0".

Returns:

dataPadding  

getLegend

jsx3.chart.Legend getLegend()
Find the first Legend child

Returns:

 

getLegendEntryType

int getLegendEntryType()
in general the chart legend renders one entry for every series in the chart, override this method to show categories in the legend

Returns:

jsx3.chart.Legend.SHOW_SERIES  

getLegendPlacement

String getLegendPlacement()
Returns the legendPlacement field, the quadrant in which to place the legend.

Returns:

legendPlacement, one of {'top','right','bottom','left'}  

getSeries

Array<jsx3.chart.Series> getSeries()
Returns the list of Series children.

Returns:

 

getSeriesIndex

int getSeriesIndex(s : jsx3.chart.Series)
Returns the index of a series in the list of series children.

Parameters:

s

Returns:

the index or -1 if not found  

getTitlePlacement

String getTitlePlacement()
Returns the titlePlacement field, the quadrant in which to place the title.

Returns:

titlePlacement, one of {'top','right','bottom','left'}  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

redrawRecord

void redrawRecord()
Note that this method is very expensive because it causes the entire chart to be redrawn. It is recommended that the methods in the CDF interface which cause this method to be called, be passed bRedraw=false to prevent this method from being called.

Overrides:


setAlpha

void setAlpha(alpha : float)
Sets the alpha field.

Parameters:

alphathe new value for alpha

setBorderAlpha

void setBorderAlpha(borderAlpha : float)
Sets the borderAlpha field.

Parameters:

borderAlphathe new value for borderAlpha

setBorderColor

void setBorderColor(borderColor : String | Number)
Sets the borderColor field.

Parameters:

borderColorthe new value for borderColor

setBorderWidth

void setBorderWidth(borderWidth : int)
Sets the borderWidth field.

Parameters:

borderWidththe new value for borderWidth

setDataPadding

void setDataPadding(dataPadding : String)
Sets the dataPadding field.

Parameters:

dataPaddingthe new value for dataPadding

setLegendPlacement

void setLegendPlacement(legendPlacement : String)
Sets the legendPlacement field.

Parameters:

legendPlacementthe new value for legendPlacement, one of {'top','right','bottom','left'}

setTitlePlacement

void setTitlePlacement(titlePlacement : String)
Sets the titlePlacement field.

Parameters:

titlePlacementthe new value for titlePlacement, one of {'top','right','bottom','left'}

jsx3.chart

class ChartComponent

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.Axis, jsx3.chart.ChartLabel, jsx3.chart.GridLines, jsx3.chart.Legend, jsx3.chart.Series

class ChartComponent
extends jsx3.gui.Block
A base class for every logical component of a chart. A chart component exists in the DOM tree and is selectable with ctrl-click in a component editor in General Interface Builder.

Constructor Summary
void
init(name : String)
The instance initializer.
Method Summary
jsx3.chart.Chart
Returns the chart of which this component is a part.
static String
Deprecated.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String)
The instance initializer.

Parameters:

namethe GI name of the instance
Method Detail

getChart

jsx3.chart.Chart getChart()
Returns the chart of which this component is a part.

Returns:

this if this is a chart, or the first ancestor that is a chart  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

jsx3.chart

class ChartLabel

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.ChartLabel

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class ChartLabel
extends jsx3.chart.ChartComponent
A chart component to render a text box. Used to render the titles of charts, legends, axes, and series. Encapsulates all the font settings of the label so that the parent container does not experience property bloat.

Field Summary
static int
the default preferred width
static int
angle for one-quarter counter-clockwise rotation
static int
angle for one-quarter clockwise rotation
static int
non-rotated angle
Constructor Summary
void
init(name : String, text : String)
The instance initializer.
Method Summary
float
Returns the alpha field, the opacity of the background fill.
String
Returns the borderStroke field, string representation of the VectorStroke used to outline the background.
int
Returns the labelRotation field.
int
Returns the preferredHeight field.
int
Returns the preferredWidth field.
String
Returns the text field.
static String
Deprecated.
boolean
whether this label is display at 90 or -90 degrees
void
setAlpha(alpha : float)
Sets the alpha field.
void
setBorderStroke(borderStroke : String)
Sets the borderStroke field.
void
setLabelRotation(labelRotation : int)
Sets the labelRotation field.
void
setPreferredHeight(preferredHeight : int)
Sets the preferredHeight field.
void
setPreferredWidth(preferredWidth : int)
Sets the preferredWidth field.
void
setText(text : String)
Sets the text field.
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_WIDTH

static int DEFAULT_WIDTH
the default preferred width

ROTATION_CCW

static final int ROTATION_CCW
angle for one-quarter counter-clockwise rotation

ROTATION_CW

static final int ROTATION_CW
angle for one-quarter clockwise rotation

ROTATION_NORMAL

static final int ROTATION_NORMAL
non-rotated angle
Constructor Detail

init

void init(name : String, text : String)
The instance initializer.

Parameters:

namethe GI name of the instance
texttext to display in the label
Method Detail

getAlpha

float getAlpha()
Returns the alpha field, the opacity of the background fill.

Returns:

alpha  

getBorderStroke

String getBorderStroke()
Returns the borderStroke field, string representation of the VectorStroke used to outline the background.

Returns:

borderStroke  

getLabelRotation

int getLabelRotation()
Returns the labelRotation field.

Returns:

labelRotation  

getPreferredHeight

int getPreferredHeight()
Returns the preferredHeight field.

Returns:

preferredHeight  

getPreferredWidth

int getPreferredWidth()
Returns the preferredWidth field.

Returns:

preferredWidth  

getText

String getText()
Returns the text field.

Returns:

text  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

isRotated

boolean isRotated()
whether this label is display at 90 or -90 degrees

Returns:

 

setAlpha

void setAlpha(alpha : float)
Sets the alpha field.

Parameters:

alphathe new value for alpha

setBorderStroke

void setBorderStroke(borderStroke : String)
Sets the borderStroke field.

Parameters:

borderStrokethe new value for borderStroke

setLabelRotation

void setLabelRotation(labelRotation : int)
Sets the labelRotation field.

Parameters:

labelRotationthe new value for labelRotation, one of {0, 90, 270}

setPreferredHeight

void setPreferredHeight(preferredHeight : int)
Sets the preferredHeight field.

Parameters:

preferredHeightthe new value for preferredHeight

setPreferredWidth

void setPreferredWidth(preferredWidth : int)
Sets the preferredWidth field.

Parameters:

preferredWidththe new value for preferredWidth

setText

void setText(text : String)
Sets the text field.

Parameters:

textthe new value for text

Overrides:


jsx3.chart

class ColumnChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.BCChart
                ->jsx3.chart.ColumnChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class ColumnChart
extends jsx3.chart.BCChart
A column chart.

Series: ColumnSeries only.
Axes: Y axis must be value axis, X axis can be value or category axis

The 'type' my be 'clustered', 'stacked', or 'stacked100', which correspond to the basic Excel-like variations of a column chart.

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
Array<Number>
getXRange(series : ?)
Array<Number>
getYRange(series : ?)
Methods Inherited From jsx3.chart.BCChart
getCategoryCoverage, getSeriesOverlap, getType, setCategoryCoverage, setSeriesOverlap, setType
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getXRange

Array<Number> getXRange(series : ?)

Parameters:

series

Returns:

[min, max].  

Overrides:


getYRange

Array<Number> getYRange(series : ?)

Parameters:

series

Returns:

[min, max].  

Overrides:


jsx3.chart

class ColumnSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.BCSeries
              ->jsx3.chart.ColumnSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class ColumnSeries
extends jsx3.chart.BCSeries
The data series type for a jsx3.chart.ColumnChart. Draws vertical columns between the x axis and a y value determined by the data provider, or between two y values determined by the data provider. A column series has the following fields:
yField
the attribute of a record to use as the vertical extent of the column, required
xField
the attribute of a record to use as the horizontal midpoint of the column, required if the x axis of the chart is a value axis
minField
the attribute of a record to use as the minimum vertical extent of the column, optional

Field Summary
static int
Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
int
Returns the columnWidth field.
void
setColumnWidth(columnWidth : int)
Sets the columnWidth field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.BCSeries
getMinField, getMinValue, getXField, getXValue, getYField, getYValue, setMinField, setXField, setYField
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_COLUMNWIDTH

static int DEFAULT_COLUMNWIDTH
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getColumnWidth

int getColumnWidth()
Returns the columnWidth field.

Returns:

columnWidth  

setColumnWidth

void setColumnWidth(columnWidth : int)
Sets the columnWidth field.

Parameters:

columnWidththe new value for columnWidth

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class GridLines

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.GridLines

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class GridLines
extends jsx3.chart.ChartComponent
A chart component that renders a grid of lines and fills aligned with an x and y axis.

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
String
Returns the borderStroke field, string representation of the stroke used to outline the grid lines.
Array<String>
Returns the fillH field, array of string representations of vector fills used to fill in areas between horizontal major ticks; if the length of the array is greater than one, the areas alternate through the list of fills.
Array<String>
Returns the fillV field, array of string representations of vector fills used to fill in areas between vertical major ticks; if the length of the array is greater than one, the areas alternate through the list of fills.
boolean
Returns the horizontalAbove field, whether to draw the horizontal lines and fills above the vertical ones.
boolean
Returns the inForeground field, whether to draw this legend on top of the data series (or below).
Array<String>
Returns the strokeMajorH field, array of string representations of VectorStroke's used to draw the horizontal major ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.
Array<String>
Returns the strokeMajorV field, array of string representations of VectorStroke's used to draw the vertical major ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.
Array<String>
Returns the strokeMinorH field, array of string representations of VectorStroke's used to draw the horizontal minor ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.
Array<String>
Returns the strokeMinorV field, array of string representations of VectorStroke's used to draw the vertical minor ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.
static String
Deprecated.
jsx3.chart.Axis
Returns the x (horizontal) axis used to determine where to draw tick lines.
jsx3.chart.Axis
Returns the y (vertical) axis used to determine where to draw tick lines.
void
setBorderStroke(borderStroke : String)
Sets the borderStroke field.
void
setFillH(fillH : Array<String>)
Sets the fillH field.
void
setFillV(fillV : Array<String>)
Sets the fillV field.
void
setHorizontalAbove(horizontalAbove : boolean)
Sets the horizontalAbove field.
void
setInForeground(inForeground : boolean)
Sets the inForeground field.
void
setStrokeMajorH(strokeMajorH : Array<String>)
Sets the strokeMajorH field.
void
setStrokeMajorV(strokeMajorV : Array<String>)
Sets the strokeMajorV field.
void
setStrokeMinorH(strokeMinorH : Array<String>)
Sets the strokeMinorH field.
void
setStrokeMinorV(strokeMinorV : Array<String>)
Sets the strokeMinorV field.
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getBorderStroke

String getBorderStroke()
Returns the borderStroke field, string representation of the stroke used to outline the grid lines.

Returns:

borderStroke  

getFillH

Array<String> getFillH()
Returns the fillH field, array of string representations of vector fills used to fill in areas between horizontal major ticks; if the length of the array is greater than one, the areas alternate through the list of fills.

Returns:

fillH  

getFillV

Array<String> getFillV()
Returns the fillV field, array of string representations of vector fills used to fill in areas between vertical major ticks; if the length of the array is greater than one, the areas alternate through the list of fills.

Returns:

fillV  

getHorizontalAbove

boolean getHorizontalAbove()
Returns the horizontalAbove field, whether to draw the horizontal lines and fills above the vertical ones.

Returns:

horizontalAbove  

getInForeground

boolean getInForeground()
Returns the inForeground field, whether to draw this legend on top of the data series (or below).

Returns:

inForeground  

getStrokeMajorH

Array<String> getStrokeMajorH()
Returns the strokeMajorH field, array of string representations of VectorStroke's used to draw the horizontal major ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.

Returns:

strokeMajorH  

getStrokeMajorV

Array<String> getStrokeMajorV()
Returns the strokeMajorV field, array of string representations of VectorStroke's used to draw the vertical major ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.

Returns:

strokeMajorV  

getStrokeMinorH

Array<String> getStrokeMinorH()
Returns the strokeMinorH field, array of string representations of VectorStroke's used to draw the horizontal minor ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.

Returns:

strokeMinorH  

getStrokeMinorV

Array<String> getStrokeMinorV()
Returns the strokeMinorV field, array of string representations of VectorStroke's used to draw the vertical minor ticks; if the length of the array is greater than one, the ticks alternate through the list of strokes.

Returns:

strokeMinorV  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXAxis

jsx3.chart.Axis getXAxis()
Returns the x (horizontal) axis used to determine where to draw tick lines.

Returns:

 

getYAxis

jsx3.chart.Axis getYAxis()
Returns the y (vertical) axis used to determine where to draw tick lines.

Returns:

 

setBorderStroke

void setBorderStroke(borderStroke : String)
Sets the borderStroke field.

Parameters:

borderStrokethe new value for borderStroke

setFillH

void setFillH(fillH : Array<String>)
Sets the fillH field.

Parameters:

fillHthe new value for fillH

setFillV

void setFillV(fillV : Array<String>)
Sets the fillV field.

Parameters:

fillVthe new value for fillV

setHorizontalAbove

void setHorizontalAbove(horizontalAbove : boolean)
Sets the horizontalAbove field.

Parameters:

horizontalAbovethe new value for horizontalAbove

setInForeground

void setInForeground(inForeground : boolean)
Sets the inForeground field.

Parameters:

inForegroundthe new value for inForeground

setStrokeMajorH

void setStrokeMajorH(strokeMajorH : Array<String>)
Sets the strokeMajorH field.

Parameters:

strokeMajorHthe new value for strokeMajorH

setStrokeMajorV

void setStrokeMajorV(strokeMajorV : Array<String>)
Sets the strokeMajorV field.

Parameters:

strokeMajorVthe new value for strokeMajorV

setStrokeMinorH

void setStrokeMinorH(strokeMinorH : Array<String>)
Sets the strokeMinorH field.

Parameters:

strokeMinorHthe new value for strokeMinorH

setStrokeMinorV

void setStrokeMinorV(strokeMinorV : Array<String>)
Sets the strokeMinorV field.

Parameters:

strokeMinorVthe new value for strokeMinorV

jsx3.chart

class Legend

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Legend

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Legend
extends jsx3.chart.ChartComponent
Chart component that renders a simple legend. A legend may contain a list of series or a list of categories, depending on the type of chart.

Field Summary
static int
the default height
static int
the default width
Constructor Summary
void
init(name : String)
The instance initializer.
Method Summary
String
Returns the backgroundFill field, a string representation of the vector fill used to color in the background of the legend.
String
Returns the backgroundStroke field, a string representation of the VectorStroke used to outline the legend.
int
Returns the boxHeight field, the diameter of the box that shows the fill of each series or category.
String
Returns the labelClass field, the CSS class name applied to the name of each series or category.
String
Returns the labelStyle field, a CSS style attribute applied to the name of each series or category, ie "font-family: Arial; font-size: 10px;".
jsx3.chart.ChartLabel
Find the first jsx3.chart.ChartLabel child
int
Returns the lineHeight field, the vertical space taken for each legend entry.
int
Returns the preferredHeight field, the height that this component would like to have, though its true size is dictated by the container component.
int
Returns the preferredWidth field, the width that this component would like to have, though its true size is dictated by the container component.
static String
Deprecated.
void
setBackgroundFill(backgroundFill : String)
Sets the backgroundFill field.
void
setBackgroundStroke(backgroundStroke : String)
Sets the backgroundStroke field.
void
setBoxHeight(boxHeight : int)
Sets the boxHeight field.
void
setLabelClass(labelClass : String)
Sets the labelClass field.
void
setLabelStyle(labelStyle : String)
Sets the labelStyle field.
void
setLineHeight(lineHeight : int)
Sets the lineHeight field.
void
setPreferredHeight(preferredHeight : int)
Sets the preferredHeight field.
void
setPreferredWidth(preferredWidth : int)
Sets the preferredWidth field.
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_HEIGHT

static int DEFAULT_HEIGHT
the default height

DEFAULT_WIDTH

static int DEFAULT_WIDTH
the default width
Constructor Detail

init

void init(name : String)
The instance initializer.

Parameters:

namethe GI name of the instance
Method Detail

getBackgroundFill

String getBackgroundFill()
Returns the backgroundFill field, a string representation of the vector fill used to color in the background of the legend.

Returns:

backgroundFill  

getBackgroundStroke

String getBackgroundStroke()
Returns the backgroundStroke field, a string representation of the VectorStroke used to outline the legend.

Returns:

backgroundStroke  

getBoxHeight

int getBoxHeight()
Returns the boxHeight field, the diameter of the box that shows the fill of each series or category.

Returns:

boxHeight  

getLabelClass

String getLabelClass()
Returns the labelClass field, the CSS class name applied to the name of each series or category.

Returns:

labelClass  

getLabelStyle

String getLabelStyle()
Returns the labelStyle field, a CSS style attribute applied to the name of each series or category, ie "font-family: Arial; font-size: 10px;".

Returns:

labelStyle  

getLegendTitle

jsx3.chart.ChartLabel getLegendTitle()
Find the first jsx3.chart.ChartLabel child

Returns:

 

getLineHeight

int getLineHeight()
Returns the lineHeight field, the vertical space taken for each legend entry.

Returns:

lineHeight  

getPreferredHeight

int getPreferredHeight()
Returns the preferredHeight field, the height that this component would like to have, though its true size is dictated by the container component.

Returns:

preferredHeight  

getPreferredWidth

int getPreferredWidth()
Returns the preferredWidth field, the width that this component would like to have, though its true size is dictated by the container component.

Returns:

preferredWidth  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setBackgroundFill

void setBackgroundFill(backgroundFill : String)
Sets the backgroundFill field.

Parameters:

backgroundFillthe new value for backgroundFill

setBackgroundStroke

void setBackgroundStroke(backgroundStroke : String)
Sets the backgroundStroke field.

Parameters:

backgroundStrokethe new value for backgroundStroke

setBoxHeight

void setBoxHeight(boxHeight : int)
Sets the boxHeight field.

Parameters:

boxHeightthe new value for boxHeight

setLabelClass

void setLabelClass(labelClass : String)
Sets the labelClass field.

Parameters:

labelClassthe new value for labelClass

setLabelStyle

void setLabelStyle(labelStyle : String)
Sets the labelStyle field.

Parameters:

labelStylethe new value for labelStyle

setLineHeight

void setLineHeight(lineHeight : int)
Sets the lineHeight field.

Parameters:

lineHeightthe new value for lineHeight

setPreferredHeight

void setPreferredHeight(preferredHeight : int)
Sets the preferredHeight field.

Parameters:

preferredHeightthe new value for preferredHeight

setPreferredWidth

void setPreferredWidth(preferredWidth : int)
Sets the preferredWidth field.

Parameters:

preferredWidththe new value for preferredWidth

jsx3.chart

class LineChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.LineChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class LineChart
extends jsx3.chart.CartesianChart
A line chart.

Series: LineSeries only.
Axes: Y axis must be value axis, X axis can be value or category axis

The 'type' my be 'overlay', 'stacked', or 'stacked100', which correspond to the basic Excel-like variations of a line chart.

Field Summary
static String
static String
static String
Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
String
Returns the type field, one of {'overlay','stacked','stacked100'}.
static String
Deprecated.
void
getXRange(series : ?)
Returns the range of x values, used when x axis is value axis.
void
getYRange(series : ?)
Returns the range of y values, considers chart type.
void
setType(type : String)
Sets the type field.
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

TYPE_OVERLAY

static final String TYPE_OVERLAY

TYPE_STACKED

static final String TYPE_STACKED

TYPE_STACKED100

static final String TYPE_STACKED100
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getType

String getType()
Returns the type field, one of {'overlay','stacked','stacked100'}.

Returns:

type  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXRange

void getXRange(series : ?)
Returns the range of x values, used when x axis is value axis.

Parameters:

series

Overrides:


getYRange

void getYRange(series : ?)
Returns the range of y values, considers chart type.

Parameters:

series

Overrides:


setType

void setType(type : String)
Sets the type field.

Parameters:

typethe new value for type, one of {'overlay','stacked','stacked100'}

jsx3.chart

class LineSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.LineSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class LineSeries
extends jsx3.chart.Series
A data series for a line chart. An line series draws a set of points connected by a line. A line series has the following properties:
xField
the attribute of a record to use as the x-coordinate of points in the series, required if the x-axis is a value axis
yField
the attribute of a record to use as the y-coordinate of points in the series, required
form
defines how the area is drawn, one of {'segment','step','reverseStep','horizontal','vertical'}, defaults to 'segment'
interpolateValues
if true the the line will be continuous even over missing data points, if false the the line will break over missing data points
pointRadius
the radius of the points to render at each data point on the line, optional
pointRenderer
string that evals to an object that implements the renderer interface, optional
pointFill
string representation of a vector fill for the points
pointStroke
string representation of a VectorStroke for the points
pointGradient
string representation of a vector fill gradient for the points

Field Summary
static String
static String
static String
static String
static String
Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
String
Returns the form field.
boolean
Returns the interpolateValues field.
String
Returns the pointFill field.
String
Returns the pointGradient field.
int
Returns the pointRadius field.
jsx3.chart.PointRenderer
Returns the pointRenderer field.
String
Returns the pointStroke field.
static String
Deprecated.
String
Returns the xField field.
String
Returns the yField field.
void
setForm(form : String)
Sets the form field, checks for valid value.
void
setInterpolateValues(interpolateValues : boolean)
Sets the interpolateValues field.
void
setPointFill(pointFill : String)
Sets the pointFill field.
void
setPointGradient(pointGradient : String)
Sets the pointGradient field.
void
setPointRadius(pointRadius : int)
Sets the pointRadius field.
void
setPointRenderer(pointRenderer : String)
Sets the pointRenderer field, should eval to an object that implements the renderer interface.
void
setPointStroke(pointStroke : String)
Sets the pointStroke field.
void
setXField(xField : String)
Sets the xField field.
void
setYField(yField : String)
Sets the yField field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

FORM_HORIZONTAL

static final String FORM_HORIZONTAL

FORM_REVSTEP

static final String FORM_REVSTEP

FORM_SEGMENT

static final String FORM_SEGMENT

FORM_STEP

static final String FORM_STEP

FORM_VERTICAL

static final String FORM_VERTICAL
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getForm

String getForm()
Returns the form field.

Returns:

form  

getInterpolateValues

boolean getInterpolateValues()
Returns the interpolateValues field.

Returns:

interpolateValues  

getPointFill

String getPointFill()
Returns the pointFill field.

Returns:

pointFill  

getPointGradient

String getPointGradient()
Returns the pointGradient field.

Returns:

pointGradient  

getPointRadius

int getPointRadius()
Returns the pointRadius field.

Returns:

pointRadius  

getPointRenderer

jsx3.chart.PointRenderer getPointRenderer()
Returns the pointRenderer field.

Returns:

pointRenderer  

getPointStroke

String getPointStroke()
Returns the pointStroke field.

Returns:

pointStroke  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXField

String getXField()
Returns the xField field.

Returns:

xField  

getYField

String getYField()
Returns the yField field.

Returns:

yField  

setForm

void setForm(form : String)
Sets the form field, checks for valid value.

Parameters:

formthe new value for form, one of {'segment','step','reverseStep','horizontal','vertical'}

setInterpolateValues

void setInterpolateValues(interpolateValues : boolean)
Sets the interpolateValues field.

Parameters:

interpolateValuesthe new value for interpolateValues

setPointFill

void setPointFill(pointFill : String)
Sets the pointFill field.

Parameters:

pointFillthe new value for pointFill

setPointGradient

void setPointGradient(pointGradient : String)
Sets the pointGradient field.

Parameters:

pointGradientthe new value for pointGradient

setPointRadius

void setPointRadius(pointRadius : int)
Sets the pointRadius field.

Parameters:

pointRadiusthe new value for pointRadius

setPointRenderer

void setPointRenderer(pointRenderer : String)
Sets the pointRenderer field, should eval to an object that implements the renderer interface.

Parameters:

pointRendererthe new value for pointRenderer, as a string

setPointStroke

void setPointStroke(pointStroke : String)
Sets the pointStroke field.

Parameters:

pointStrokethe new value for pointStroke

setXField

void setXField(xField : String)
Sets the xField field.

Parameters:

xFieldthe new value for xField

setYField

void setYField(yField : String)
Sets the yField field.

Parameters:

yFieldthe new value for yField

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class LinearAxis

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Axis
            ->jsx3.chart.LinearAxis

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class LinearAxis
extends jsx3.chart.Axis
Type of axis that displays a linear range of values.

Field Summary
static int
The maximum number of intervals to show when calculating by auto adjust.
static int
The minimum number of intervals to show when calculating by auto adjust.
Constructor Summary
void
init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.
Method Summary
boolean
Returns the autoAdjust field, whether to adjust the max/min/interval to the range of the data.
boolean
Returns the baseAtZero field, whether to set either the min or max value of this axis to 0 if applicable and if autoAdjust is true.
int
convert a number value to a coordinate between 0 and this.length, if the value is outside of the range of the axis, return the closest value in the range
void
same as getCoordinateFor(), but does not clip to bounds of the axis
int
Returns the interval field, the interval between major ticks, overrides autoAdjust.
int
Returns the max field, the maximum value displayed by this axis, overrides autoAdjust.
int
Returns the min field, the minimum value displayed by this axis, overrides autoAdjust.
static String
Deprecated.
void
setAutoAdjust(autoAdjust : boolean)
Sets the autoAdjust field.
void
setBaseAtZero(baseAtZero : boolean)
Sets the baseAtZero field.
void
setInterval(interval : int)
Sets the interval field.
void
setMax(max : int)
Sets the max field.
void
setMin(min : int)
Sets the min field.
Methods Inherited From jsx3.chart.Axis
getAxisStroke, getAxisTitle, getDisplayWidth, getHorizontal, getLabelClass, getLabelColor, getLabelFunction, getLabelGap, getLabelStyle, getMinorTickDivisions, getMinorTickLength, getMinorTickPlacement, getMinorTickStroke, getOpposingAxis, getShowAxis, getShowLabels, getTickLength, getTickPlacement, getTickStroke, setAxisStroke, setDisplayWidth, setHorizontal, setLabelClass, setLabelColor, setLabelFunction, setLabelGap, setLabelPlacement, setLabelStyle, setMinorTickDivisions, setMinorTickLength, setMinorTickPlacement, setMinorTickStroke, setShowAxis, setShowLabels, setTickLength, setTickPlacement, setTickStroke
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

MAX_INTERVALS

static int MAX_INTERVALS
The maximum number of intervals to show when calculating by auto adjust.

MIN_INTERVALS

static int MIN_INTERVALS
The minimum number of intervals to show when calculating by auto adjust.
Constructor Detail

init

void init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.

Parameters:

namethe GI name of the instance
horizontalwhether this axis is horizontal (x), otherwise it's vertical (y)
primarywhether this axis is primary, otherwise it's secondary
Method Detail

getAutoAdjust

boolean getAutoAdjust()
Returns the autoAdjust field, whether to adjust the max/min/interval to the range of the data.

Returns:

autoAdjust  

getBaseAtZero

boolean getBaseAtZero()
Returns the baseAtZero field, whether to set either the min or max value of this axis to 0 if applicable and if autoAdjust is true.

Returns:

baseAtZero  

getCoordinateFor

int getCoordinateFor(value : Number)
convert a number value to a coordinate between 0 and this.length, if the value is outside of the range of the axis, return the closest value in the range

Parameters:

valuea value displayed along the axis

Returns:

coordinate along the axis  

getCoordinateForNoClip

void getCoordinateForNoClip(value : ?)
same as getCoordinateFor(), but does not clip to bounds of the axis

Parameters:

value

getInterval

int getInterval()
Returns the interval field, the interval between major ticks, overrides autoAdjust.

Returns:

interval  

getMax

int getMax()
Returns the max field, the maximum value displayed by this axis, overrides autoAdjust.

Returns:

max  

getMin

int getMin()
Returns the min field, the minimum value displayed by this axis, overrides autoAdjust.

Returns:

min  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setAutoAdjust

void setAutoAdjust(autoAdjust : boolean)
Sets the autoAdjust field.

Parameters:

autoAdjustthe new value for autoAdjust

setBaseAtZero

void setBaseAtZero(baseAtZero : boolean)
Sets the baseAtZero field.

Parameters:

baseAtZerothe new value for baseAtZero

setInterval

void setInterval(interval : int)
Sets the interval field.

Parameters:

intervalthe new value for interval

setMax

void setMax(max : int)
Sets the max field.

Parameters:

maxthe new value for max

setMin

void setMin(min : int)
Sets the min field.

Parameters:

minthe new value for min

jsx3.chart

class LogarithmicAxis

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Axis
            ->jsx3.chart.LogarithmicAxis

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class LogarithmicAxis
extends jsx3.chart.Axis
An axis that displays a range of values logarithmically (base^n and base^(n+1) occupy same visual space).

Constructor Summary
void
init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.
Method Summary
boolean
Returns the autoAdjust field.
int
Returns the base field.
boolean
Returns the baseAtZero field, whether or not to set the minimum value to base^0, otherwise will choose an appropriate value for the data range.
int
convert a number value to a coordinate between 0 and this.length, if the value is outside of the range of the axis, return the closest value in the range
void
same as getCoordinateFor(), but does not clip to bounds of the axis
int
Returns the majorDivisions field, the number of major tick line divisions to place between the values base^n and base^(n+1).
int
Returns the maxExponent field, the range of values displayed will end at base^maxExponent.
int
Returns the minExponent field, the range of values displayed will begin at base^minExpronent.
boolean
Returns the showNegativeValues field.
static String
Deprecated.
void
setAutoAdjust(autoAdjust : boolean)
Sets the autoAdjust field.
void
setBase(base : int)
Sets the base field.
void
setBaseAtZero(baseAtZero : boolean)
Sets the baseAtZero field.
void
setMajorDivisions(majorDivisions : int)
Sets the majorDivisions field.
void
setMaxExponent(maxExponent : int)
Sets the maxExponent field.
void
setMinExponent(minExponent : int)
Sets the minExponent field.
void
setShowNegativeValues(showNegativeValues : boolean)
Sets the showNegativeValues field.
Methods Inherited From jsx3.chart.Axis
getAxisStroke, getAxisTitle, getDisplayWidth, getHorizontal, getLabelClass, getLabelColor, getLabelFunction, getLabelGap, getLabelStyle, getMinorTickDivisions, getMinorTickLength, getMinorTickPlacement, getMinorTickStroke, getOpposingAxis, getShowAxis, getShowLabels, getTickLength, getTickPlacement, getTickStroke, setAxisStroke, setDisplayWidth, setHorizontal, setLabelClass, setLabelColor, setLabelFunction, setLabelGap, setLabelPlacement, setLabelStyle, setMinorTickDivisions, setMinorTickLength, setMinorTickPlacement, setMinorTickStroke, setShowAxis, setShowLabels, setTickLength, setTickPlacement, setTickStroke
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, horizontal : boolean, primary : boolean)
The instance initializer.

Parameters:

namethe GI name of the instance
horizontalwhether this axis is horizontal (x), otherwise it's vertical (y)
primarywhether this axis is primary, otherwise it's secondary
Method Detail

getAutoAdjust

boolean getAutoAdjust()
Returns the autoAdjust field.

Returns:

autoAdjust  

getBase

int getBase()
Returns the base field.

Returns:

base  

getBaseAtZero

boolean getBaseAtZero()
Returns the baseAtZero field, whether or not to set the minimum value to base^0, otherwise will choose an appropriate value for the data range.

Returns:

baseAtZero  

getCoordinateFor

int getCoordinateFor(value : Number)
convert a number value to a coordinate between 0 and this.length, if the value is outside of the range of the axis, return the closest value in the range

Parameters:

valuea value displayed along the axis

Returns:

coordinate along the axis  

getCoordinateForNoClip

void getCoordinateForNoClip(value : ?)
same as getCoordinateFor(), but does not clip to bounds of the axis

Parameters:

value

getMajorDivisions

int getMajorDivisions()
Returns the majorDivisions field, the number of major tick line divisions to place between the values base^n and base^(n+1). A good value can be base-1, though the default value is 1..

Returns:

majorDivisions  

getMaxExponent

int getMaxExponent()
Returns the maxExponent field, the range of values displayed will end at base^maxExponent.

Returns:

maxExponent  

getMinExponent

int getMinExponent()
Returns the minExponent field, the range of values displayed will begin at base^minExpronent.

Returns:

minExponent  

getShowNegativeValues

boolean getShowNegativeValues()
Returns the showNegativeValues field.

Returns:

showNegativeValues  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setAutoAdjust

void setAutoAdjust(autoAdjust : boolean)
Sets the autoAdjust field.

Parameters:

autoAdjustthe new value for autoAdjust

setBase

void setBase(base : int)
Sets the base field.

Parameters:

basethe new value for base

setBaseAtZero

void setBaseAtZero(baseAtZero : boolean)
Sets the baseAtZero field.

Parameters:

baseAtZerothe new value for baseAtZero

setMajorDivisions

void setMajorDivisions(majorDivisions : int)
Sets the majorDivisions field.

Parameters:

majorDivisionsthe new value for majorDivisions

setMaxExponent

void setMaxExponent(maxExponent : int)
Sets the maxExponent field.

Parameters:

maxExponentthe new value for maxExponent

setMinExponent

void setMinExponent(minExponent : int)
Sets the minExponent field.

Parameters:

minExponentthe new value for minExponent

setShowNegativeValues

void setShowNegativeValues(showNegativeValues : boolean)
Sets the showNegativeValues field.

Parameters:

showNegativeValuesthe new value for showNegativeValues

jsx3.chart

class PieChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.RadialChart
              ->jsx3.chart.PieChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class PieChart
extends jsx3.chart.RadialChart
A pie chart.

Series: PieSeries only.
Axes: No axes, it's a radial chart.

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
static jsx3.vector.Fill
defaultColoring(record : jsx3.xml.Entity, index : int)
default coloring scheme for pie series, simply converts the default coloring scheme for series into a coloring scheme for categories
String
Returns the categoryField field, the attribute of a record that contains the category name value; necessary because there is no CategoryAxis to define this in a radial chart.
Function
Returns the colorFunction field, a function that defines how to color in the slices of each data series in this chart, with the signature function(record, index) : jsx3.vector.Fill; may be overridden by jsx3.chart.PieSeries.colorFunction for an individual series.
Array<String | int>
Returns the colors field, an array of string representations of a vector fill, to color in the slices of all the data series; may be overridden by jsx3.chart.PieSeries.colors for an individual series.
float
Returns the innerRadius field, the radius as the hole in the middle of the pie as a ratio of the entire radius.
float
Returns the seriesPadding field, the amount of padding between rings in a doughnut chart as a ratio of the width of a ring.
String
Returns the seriesStroke field, string representation of a VectorStroke to outline the slices of all the series with; may be overridden by jsx3.chart.PieSeries.stroke for an individual series.
int
Returns the startAngle field, the start angle of the first slice in each series; 0 points upwards and increasing values go clockwise; may be overridden on a series-by-series basis by jsx3.chart.PieSeries.startAngle.
int
Returns the totalAngle field, the total angle used for each series; may be overridden on a series-by-series basis by jsx3.chart.PieSeries.totalAngle.
static String
Deprecated.
void
setCategoryField(categoryField : String)
Sets the categoryField field.
void
setColorFunction(colorFunction : String | Function)
Sets the colorFunction field.
void
setColors(colors : Array<String | int>)
Sets the colors field.
void
setInnerRadius(innerRadius : float)
Sets the innerRadius field.
void
setSeriesPadding(seriesPadding : float)
Sets the seriesPadding field.
void
setSeriesStroke(seriesStroke : String)
Sets the seriesStroke field.
void
setStartAngle(startAngle : int)
Sets the startAngle field.
void
setTotalAngle(totalAngle : int)
Sets the totalAngle field.
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

defaultColoring

static jsx3.vector.Fill defaultColoring(record : jsx3.xml.Entity, index : int)
default coloring scheme for pie series, simply converts the default coloring scheme for series into a coloring scheme for categories

Parameters:

record
indexthe index of the record in the data provider

Returns:

 

getCategoryField

String getCategoryField()
Returns the categoryField field, the attribute of a record that contains the category name value; necessary because there is no CategoryAxis to define this in a radial chart.

Returns:

categoryField  

getColorFunction

Function getColorFunction()
Returns the colorFunction field, a function that defines how to color in the slices of each data series in this chart, with the signature function(record, index) : jsx3.vector.Fill; may be overridden by jsx3.chart.PieSeries.colorFunction for an individual series..

Returns:

colorFunction  

getColors

Array<String | int> getColors()
Returns the colors field, an array of string representations of a vector fill, to color in the slices of all the data series; may be overridden by jsx3.chart.PieSeries.colors for an individual series..

Returns:

colors  

getInnerRadius

float getInnerRadius()
Returns the innerRadius field, the radius as the hole in the middle of the pie as a ratio of the entire radius.

Returns:

innerRadius  

getSeriesPadding

float getSeriesPadding()
Returns the seriesPadding field, the amount of padding between rings in a doughnut chart as a ratio of the width of a ring.

Returns:

seriesPadding  

getSeriesStroke

String getSeriesStroke()
Returns the seriesStroke field, string representation of a VectorStroke to outline the slices of all the series with; may be overridden by jsx3.chart.PieSeries.stroke for an individual series..

Returns:

seriesStroke  

getStartAngle

int getStartAngle()
Returns the startAngle field, the start angle of the first slice in each series; 0 points upwards and increasing values go clockwise; may be overridden on a series-by-series basis by jsx3.chart.PieSeries.startAngle.

Returns:

startAngle  

getTotalAngle

int getTotalAngle()
Returns the totalAngle field, the total angle used for each series; may be overridden on a series-by-series basis by jsx3.chart.PieSeries.totalAngle.

Returns:

totalAngle  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setCategoryField

void setCategoryField(categoryField : String)
Sets the categoryField field.

Parameters:

categoryFieldthe new value for categoryField

setColorFunction

void setColorFunction(colorFunction : String | Function)
Sets the colorFunction field. Note that passing a function reference to this method will prevent the color function from persisting if this object is serialized. The function will be applied to this object when called.

Parameters:

colorFunctionthe new value for colorFunction, a function with the signature function(record : jsx3.xml.Entity, index : Number) : jsx3.vector.Fill.

setColors

void setColors(colors : Array<String | int>)
Sets the colors field.

Parameters:

colorsthe new value for colors

setInnerRadius

void setInnerRadius(innerRadius : float)
Sets the innerRadius field.

Parameters:

innerRadiusthe new value for innerRadius, between 0.0 and 1.0

setSeriesPadding

void setSeriesPadding(seriesPadding : float)
Sets the seriesPadding field.

Parameters:

seriesPaddingthe new value for seriesPadding, positive value, not too big

setSeriesStroke

void setSeriesStroke(seriesStroke : String)
Sets the seriesStroke field.

Parameters:

seriesStrokethe new value for seriesStroke

setStartAngle

void setStartAngle(startAngle : int)
Sets the startAngle field.

Parameters:

startAnglethe new value for startAngle, between 0 and 360

setTotalAngle

void setTotalAngle(totalAngle : int)
Sets the totalAngle field.

Parameters:

totalAnglethe new value for totalAngle, between 0 and 360

jsx3.chart

class PieSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.PieSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class PieSeries
extends jsx3.chart.Series
A data series for a pie chart. Draws a complete pie or ring of a doughnut. A pie series is slightly different from all the other series because it gets colored in by category instead of all one color. A pie series has the following fields:
xField
the attribute of a record to use as the relative size of each slice of the pie, required
totalAngle
the total angle for the series, if not set use the value from the chart
startAngle
the angle of the start of the first slice, 0 is top and increasing values go clockwise, if not set use the value from the chart
colors
an array of string representations of vector fills to color in the slices, if not set use the value from the chart
colorFunction
a function that determines the color of each slice, with the signature function(record, index) : jsx3.vector.Fill, if not set use the value from the chart
stroke
string representation of a VectorStroke to outline the slices with, if not set use the value from the chart
labelPlacement
where to place a label with the name of the series, relative to the series, one of {'top','right','bottom','left'}
labelOffset
the padding (may be negative) between the outer edge of the series and the close edge of the label

Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
Array<String | int>
Returns the colors field, overrides per-chart setting in PieChart.
String
Returns the field field, the attribute of the data provider to use as values for this series.
int
Returns the labelOffset field, the pixel offset of the optional ChartLabel child.
String
Returns the labelPlacement field, where to place the optional ChartLabel child.
int
Returns the startAngle field, overrides per-chart setting in PieChart.
int
Returns the totalAngle field, overrides per-chart setting in PieChart.
Number
Returns the value of a data point in this series for the given record.
static String
Deprecated.
void
setColors(colors : Array<String | int>)
Sets the colors field.
void
setField(field : String)
Sets the field field.
void
setLabelOffset(labelOffset : int)
Sets the labelOffset field.
void
setLabelPlacement(labelPlacement : String)
Sets the labelPlacement field.
void
setStartAngle(startAngle : int)
Sets the startAngle field.
void
setTotalAngle(totalAngle : int)
Sets the totalAngle field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity, percent : ?)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getColors

Array<String | int> getColors()
Returns the colors field, overrides per-chart setting in PieChart.

Returns:

colors  

getField

String getField()
Returns the field field, the attribute of the data provider to use as values for this series.

Returns:

field  

getLabelOffset

int getLabelOffset()
Returns the labelOffset field, the pixel offset of the optional ChartLabel child.

Returns:

labelOffset  

getLabelPlacement

String getLabelPlacement()
Returns the labelPlacement field, where to place the optional ChartLabel child.

Returns:

labelPlacement  

getStartAngle

int getStartAngle()
Returns the startAngle field, overrides per-chart setting in PieChart.

Returns:

startAngle  

getTotalAngle

int getTotalAngle()
Returns the totalAngle field, overrides per-chart setting in PieChart.

Returns:

totalAngle  

getValue

Number getValue(record : jsx3.xml.Entity)
Returns the value of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

setColors

void setColors(colors : Array<String | int>)
Sets the colors field.

Parameters:

colorsthe new value for colors

setField

void setField(field : String)
Sets the field field.

Parameters:

fieldthe new value for field

setLabelOffset

void setLabelOffset(labelOffset : int)
Sets the labelOffset field.

Parameters:

labelOffsetthe new value for labelOffset

setLabelPlacement

void setLabelPlacement(labelPlacement : String)
Sets the labelPlacement field.

Parameters:

labelPlacementthe new value for labelPlacement

setStartAngle

void setStartAngle(startAngle : int)
Sets the startAngle field.

Parameters:

startAnglethe new value for startAngle

setTotalAngle

void setTotalAngle(totalAngle : int)
Sets the totalAngle field.

Parameters:

totalAnglethe new value for totalAngle

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity, percent : ?)
The default tooltip function for this type of series.

Parameters:

series
record
percent

Returns:

 

jsx3.chart

class PlotChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.CartesianChart
              ->jsx3.chart.PlotChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class PlotChart
extends jsx3.chart.CartesianChart
An plot (scatter/point/bubble) chart.

Series: PointSeries, BubbleSeries Axes: both X and Y axis must be value axes

Field Summary
static String
static String
static String
static String
Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
String
Returns the magnitudeMethod field; the magnitude method defines how the magnitude value of a record in a bubble series is converted to a radius for the rendered point; a value of "radius" means that the magnitude will equal the radius of the point, "diameter" means that the magnitude will equal the diameter (2 * radius), and "area" means that the area of the point will be proportional to the magnitude.
int
Returns the maxPointRadius field, limit the radius of points on this chart to this value.
static String
Deprecated.
void
getXRange(series : ?)
Returns the range of x values.
void
getYRange(series : ?)
Returns the range of y values.
void
setMagnitudeMethod(magnitudeMethod : String)
Sets the magnitudeMethod field, one of {"radius","diameter","area"}.
void
setMaxPointRadius(maxPointRadius : int)
Sets the maxPointRadius field.
Methods Inherited From jsx3.chart.CartesianChart
getGridLines, getPrimaryXAxis, getPrimaryYAxis, getRangeForAxis
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_MAX_POINT_RADIUS

static String DEFAULT_MAX_POINT_RADIUS

MAG_AREA

static final String MAG_AREA

MAG_DIAMETER

static final String MAG_DIAMETER

MAG_RADIUS

static final String MAG_RADIUS
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

getMagnitudeMethod

String getMagnitudeMethod()
Returns the magnitudeMethod field; the magnitude method defines how the magnitude value of a record in a bubble series is converted to a radius for the rendered point; a value of "radius" means that the magnitude will equal the radius of the point, "diameter" means that the magnitude will equal the diameter (2 * radius), and "area" means that the area of the point will be proportional to the magnitude.

Returns:

magnitudeMethod, one of {"radius","diameter","area"}  

getMaxPointRadius

int getMaxPointRadius()
Returns the maxPointRadius field, limit the radius of points on this chart to this value.

Returns:

maxPointRadius  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXRange

void getXRange(series : ?)
Returns the range of x values.

Parameters:

series

Overrides:


getYRange

void getYRange(series : ?)
Returns the range of y values.

Parameters:

series

Overrides:


setMagnitudeMethod

void setMagnitudeMethod(magnitudeMethod : String)
Sets the magnitudeMethod field, one of {"radius","diameter","area"}.

Parameters:

magnitudeMethodthe new value for magnitudeMethod

setMaxPointRadius

void setMaxPointRadius(maxPointRadius : int)
Sets the maxPointRadius field.

Parameters:

maxPointRadiusthe new value for maxPointRadius

jsx3.chart

class PlotSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.PlotSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.BubbleSeries, jsx3.chart.PointSeries

class PlotSeries
extends jsx3.chart.Series
Class encapsulating behavior shared by PointSeries and BubbleSeries

Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
jsx3.chart.PointRenderer
Returns the renderer used for the legend.
jsx3.chart.PointRenderer
Returns the renderer field.
static String
Deprecated.
String
Returns the xField field.
Number
Returns the x-coordinate of a data point in this series for the given record.
String
Returns the yField field.
Number
Returns the y-coordinate of a data point in this series for the given record.
void
setRenderer(renderer : String)
Sets the renderer field.
void
setXField(xField : String)
Sets the xField field.
void
setYField(yField : String)
Sets the yField field.
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getLegendRenderer

jsx3.chart.PointRenderer getLegendRenderer()
Returns the renderer used for the legend.

Returns:

the same renderer as used to draw the points  

getRenderer

jsx3.chart.PointRenderer getRenderer()
Returns the renderer field.

Returns:

renderer  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXField

String getXField()
Returns the xField field.

Returns:

xField  

getXValue

Number getXValue(record : jsx3.xml.Entity)
Returns the x-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

getYField

String getYField()
Returns the yField field.

Returns:

yField  

getYValue

Number getYValue(record : jsx3.xml.Entity)
Returns the y-coordinate of a data point in this series for the given record.

Parameters:

recordthe node

Returns:

 

setRenderer

void setRenderer(renderer : String)
Sets the renderer field.

Parameters:

rendererthe new value for renderer

setXField

void setXField(xField : String)
Sets the xField field.

Parameters:

xFieldthe new value for xField

setYField

void setYField(yField : String)
Sets the yField field.

Parameters:

yFieldthe new value for yField

jsx3.chart

interface PointRenderer

jsx3.chart.PointRenderer

abstract interface PointRenderer
Objects that implement this interface may be used in Line/Area/Point/Bubble charts to render the points that appear at each datapoint.

Additionally, this interface contains several static fields that are implementors of this interface.

Field Summary
static jsx3.chart.PointRenderer
Creates a square point.
static jsx3.chart.PointRenderer
Creates a circular point.
static jsx3.chart.PointRenderer
Creates a x-shaped cross point.
static jsx3.chart.PointRenderer
Creates a diamond shaped point.
static jsx3.chart.PointRenderer
Creates an upward-pointing triangular point.
Method Summary
abstract Number
Converts the area of the point to display to the radius of the box that it should fill.
abstract jsx3.vector.Tag
render(x1 : int, y1 : int, x2 : int, y2 : int, fill : jsx3.vector.Fill, stroke : jsx3.vector.Stroke)
Renders the point in the bounds specified by {x1,y1} {x2,y2}.
Field Detail

BOX

static jsx3.chart.PointRenderer BOX
Creates a square point.

CIRCLE

static jsx3.chart.PointRenderer CIRCLE
Creates a circular point.

CROSS

static jsx3.chart.PointRenderer CROSS
Creates a x-shaped cross point.

DIAMOND

static jsx3.chart.PointRenderer DIAMOND
Creates a diamond shaped point.

TRIANGLE

static jsx3.chart.PointRenderer TRIANGLE
Creates an upward-pointing triangular point.
Method Detail

areaToRadius

abstract Number areaToRadius(area : Number)
Converts the area of the point to display to the radius of the box that it should fill. Required if the point renderer will be used in a plot chart.

Parameters:

area

Returns:

 

render

abstract jsx3.vector.Tag render(x1 : int, y1 : int, x2 : int, y2 : int, fill : jsx3.vector.Fill, stroke : jsx3.vector.Stroke)
Renders the point in the bounds specified by {x1,y1} {x2,y2}.

Parameters:

x1
y1
x2
y2
fill
stroke

Returns:

 

jsx3.chart

class PointSeries

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series
            ->jsx3.chart.PlotSeries
              ->jsx3.chart.PointSeries

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class PointSeries
extends jsx3.chart.PlotSeries
A data series used for a jsx3.chart.PointChart. A point series has the following fields: xField - the attribute of a record to use as the x-coordinate of points in the series, required yField - the attribute of a record to use as the y-coordinate of points in the series, required magnitude - the magnitude of all the points in the series pointRenderer - string that evals to an object that implements the renderer interface, optional

Field Summary
static int
Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
int
Returns the magnitude field, the magnitude value to use for each data point in this series.
void
setMagnitude(magnitude : int)
Sets the magnitude field.
static String
tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.
Methods Inherited From jsx3.chart.PlotSeries
getLegendRenderer, getRenderer, getXField, getXValue, getYField, getYValue, setRenderer, setXField, setYField
Methods Inherited From jsx3.chart.Series
getColorFunction, getFill, getFillGradient, getIndex, getLabel, getSeriesName, getStroke, getTooltipFunction, getXAxis, getYAxis, setColorFunction, setFill, setFillGradient, setSeriesName, setStroke, setTooltipFunction
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_MAGNITUDE

static int DEFAULT_MAGNITUDE
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getMagnitude

int getMagnitude()
Returns the magnitude field, the magnitude value to use for each data point in this series.

Returns:

magnitude  

setMagnitude

void setMagnitude(magnitude : int)
Sets the magnitude field.

Parameters:

magnitudethe new value for magnitude

tooltip

static String tooltip(series : jsx3.chart.Series, record : jsx3.xml.Entity)
The default tooltip function for this type of series.

Parameters:

series
record

Returns:

 

jsx3.chart

class RadialChart

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block
          ->jsx3.chart.Chart
            ->jsx3.chart.RadialChart

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

Direct Known Subclasses:

jsx3.chart.PieChart

class RadialChart
extends jsx3.chart.Chart
Base class for radial charts (pie chart is only example so far).

Constructor Summary
void
init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
static Number
Deprecated. Use jsx3.vector.degreesToRadians() instead.
static String
Deprecated.
Methods Inherited From jsx3.chart.Chart
getAlpha, getBorderAlpha, getBorderColor, getBorderWidth, getChartTitle, getDataPadding, getLegend, getLegendEntryType, getLegendPlacement, getSeries, getSeriesIndex, getTitlePlacement, redrawRecord, setAlpha, setBorderAlpha, setBorderColor, setBorderWidth, setDataPadding, setLegendPlacement, setTitlePlacement
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.vector.Block
createCanvas, createVector, getCanvas, paintEventHandler, updateVector
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

namethe GI name of the instance
leftleft position (in pixels) of the chart relative to its parent container
toptop position (in pixels) of the chart relative to its parent container
widthwidth (in pixels) of the chart
heightheight (in pixels) of the chart
Method Detail

degreesToRadians

static Number degreesToRadians(degrees : Number)
Deprecated. Use jsx3.vector.degreesToRadians() instead.
convert degrees (0 at top, clockwise) to radians (0 at right, counterclockwise)

Parameters:

degreesa degree value; 0 points upwards, increasing values go clockwise

Returns:

a radian value, between 0 and 2*pi; 0 points rightwards, increasing values go counterclockwise 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

jsx3.chart

class Series

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.chart.ChartComponent
          ->jsx3.chart.Series

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.AreaSeries, jsx3.chart.BCSeries, jsx3.chart.LineSeries, jsx3.chart.PieSeries, jsx3.chart.PlotSeries

class Series
extends jsx3.chart.ChartComponent
The base class for all data series classes. In general, a chart is made up of a fixed number of configured series and a variable number of categories. A series is essentially an addressing scheme that defines how to get information out of each category.

Constructor Summary
void
init(name : String, seriesName : String)
The instance initializer.
Method Summary
Function
Returns the colorFunction field.
String
Returns the fill field.
String
Returns the fillGradient field.
int
Returns the index of this series in the list of chart's series.
jsx3.chart.ChartLabel
Returns the optional jsx3.chart.ChartLabel child of this series.
String
Returns the seriesName field.
String
Returns the stroke field.
Function
Returns the function used to render tooltips for each area drawn by this series.
static String
Deprecated.
jsx3.chart.Axis
Returns the x axis that this series is plotted against.
jsx3.chart.Axis
Returns the y axis that this series is plotted against.
void
setColorFunction(colorFunction : String | Function)
Sets the colorFunction field.
void
setFill(fill : String)
Sets the fill field, string representation of a vector fill.
void
setFillGradient(fillGradient : String)
Sets the fillGradient field, string representation of a vector fill gradient.
void
setSeriesName(seriesName : String)
Sets the seriesName field, this name is usually displayed in a legend or as a label.
void
setStroke(stroke : String)
Sets the stroke field, string representation of a VectorStroke.
void
setTooltipFunction(tooltipFunction : String | Function)
Sets the function used to render tooltips for each area drawn by this series.
Methods Inherited From jsx3.chart.ChartComponent
getChart
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(name : String, seriesName : String)
The instance initializer.

Parameters:

namethe GI name of the instance
seriesNamethe name of the Series, will be displayed in the Legend for most chart types
Method Detail

getColorFunction

Function getColorFunction()
Returns the colorFunction field.

Returns:

colorFunction 

Since:

3.1

getFill

String getFill()
Returns the fill field.

Returns:

fill  

getFillGradient

String getFillGradient()
Returns the fillGradient field.

Returns:

fillGradient  

getIndex

int getIndex()
Returns the index of this series in the list of chart's series.

Returns:

index, -1 if not found  

Overrides:


getLabel

jsx3.chart.ChartLabel getLabel()
Returns the optional jsx3.chart.ChartLabel child of this series.

Returns:

 

getSeriesName

String getSeriesName()
Returns the seriesName field.

Returns:

seriesName  

getStroke

String getStroke()
Returns the stroke field.

Returns:

stroke  

getTooltipFunction

Function getTooltipFunction()
Returns the function used to render tooltips for each area drawn by this series.

Returns:

function(series,record) : string  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

getXAxis

jsx3.chart.Axis getXAxis()
Returns the x axis that this series is plotted against.

Returns:

the x axis  

getYAxis

jsx3.chart.Axis getYAxis()
Returns the y axis that this series is plotted against.

Returns:

the y axis  

setColorFunction

void setColorFunction(colorFunction : String | Function)
Sets the colorFunction field. The function will be applied to this object when called. Note that passing a function reference to this method will prevent the color function from persisting if this object is serialized.

Parameters:

colorFunctionthe new value for colorFunction, a function with the signature function(record : jsx3.xml.Entity, index : Number) : jsx3.vector.Fill.

Since:

3.1

setFill

void setFill(fill : String)
Sets the fill field, string representation of a vector fill.

Parameters:

fillthe new value for fill

setFillGradient

void setFillGradient(fillGradient : String)
Sets the fillGradient field, string representation of a vector fill gradient.

Parameters:

fillGradientthe new value for fillGradient

setSeriesName

void setSeriesName(seriesName : String)
Sets the seriesName field, this name is usually displayed in a legend or as a label.

Parameters:

seriesNamethe new value for seriesName

setStroke

void setStroke(stroke : String)
Sets the stroke field, string representation of a VectorStroke.

Parameters:

strokethe new value for stroke

setTooltipFunction

void setTooltipFunction(tooltipFunction : String | Function)
Sets the function used to render tooltips for each area drawn by this series. The function will be applied to this object when called. Note that passing a function reference to this method will prevent the color function from persisting if this object is serialized.

Parameters:

tooltipFunctiona function with the signature function(s : jsx3.chart.Series, record : jsx3.xml.Entity) : String

package jsx3.gui

GUI classes.

Class Summary
jsx3.gui.Alerts
Mixin interface allows implementors to show alerts, confirms, and prompts.
jsx3.gui.Block
This class provides a container-based, object-oriented approach to creating static html objects (basically this class creates "DIV" objects).
jsx3.gui.BlockX
Paints the result of an XSL transformation in an Block.
jsx3.gui.Button
Provides a object-oriented interface for a standard command button.
jsx3.gui.CDF
Provides a container that maps to a CDF Document in the cache.
jsx3.gui.CheckBox
This class is a wrapper of the standard HTML checkbox.
jsx3.gui.ColorPicker
A GUI class that allows the user to pick a color using an HSB (hue-saturation-brightness) picker.
jsx3.gui.Column
Deprecated. Use jsx3.gui.Matrix.Column instead.
jsx3.gui.DatePicker
A form element that allows for the selection of an arbitrary date by showing a navigable calendar.
jsx3.gui.Dialog
Renders a dialog window.
jsx3.gui.DojoWidget
An adapter for Dojo widgets.
jsx3.gui.Event
Native browser event wrapper.
jsx3.gui.Form
Mixin interface.
jsx3.gui.Grid
Deprecated. Use jsx3.gui.Matrix instead.
jsx3.gui.Heavyweight
GUI utility class that provides a way to display HTML content on-screen in an HTML equivalent of a heavyweight container.
jsx3.gui.HotKey
Encapsulates a keydown event listener that is invoked by a certain combination of keys pressed simultaneously.
jsx3.gui.IFrame
Renders an IFrame.
jsx3.gui.Image
Renders an image.
jsx3.gui.ImageButton
An object-oriented interface onto a GUI button made of various image files.
jsx3.gui.Interactive
Mixin interface.
jsx3.gui.LayoutGrid
This class provides a way to organize a set of GUI objects in a grid.
jsx3.gui.List
Deprecated. Use jsx3.gui.Matrix instead.
jsx3.gui.Matrix
The Matrix control is the standard visual interface for the Common Data Format (CDF), providing grid and tree-grid functionality that mirrors the the record and attribute structures used by the CDF.
jsx3.gui.Matrix.BlockMask
The interface that defines the methods that affect the behavior of a composite object used as an edit mask of a matrix column.
jsx3.gui.Matrix.Column
Column control for use as a child of a jsx3.gui.Matrix class
jsx3.gui.Matrix.ColumnFormat
A class that defines the methods required for an object to be used by jsx3.gui.Matrix.Column instances to format cells of data.
jsx3.gui.Matrix.EditMask
The interface defining the methods that affect the behavior of an object used as an edit mask in a matrix column.
jsx3.gui.Menu
Create GUI menus, similar in functionality to system menus (File, Edit, etc) created by the host OS.
jsx3.gui.NumberInput
A form element (text box) that stores a number value.
jsx3.gui.Painted
Abstract superclass of model objects that are painted to screen.
jsx3.gui.RadioButton
A GUI control that implements a single radio button.
jsx3.gui.Select
The JSX version of a standard GUI select box.
jsx3.gui.Slider
A GUI control that implements a draggable slider.
jsx3.gui.Sound
Class that provides an object-oriented interface for playing sounds in a GI application.
jsx3.gui.Splitter
This class manages layouts by providing a container that will paint its first two child GUI objects separated by a 'splitter' (either vertical or horizontal).
jsx3.gui.Stack
This class is equivalent to a tab, but uses the stack metaphor; like a tab, it has one child—a block for its content; a jsx3.gui.Stack instance should only be contained by a jsx3.gui.StackGroup instance for proper rendering.
jsx3.gui.StackGroup
similar to how a tabbed pane manages a collection of tabs, the stack group is a parent container that manages JSXStack instances
jsx3.gui.Tab
Renders a tab in a tabbed pane.
jsx3.gui.TabbedPane
Renders a tabbed pane, which consists of a set of tabs, only one of which is visible at a time.
jsx3.gui.Table
A lightweight control that displays CDF data in an HTML table.
jsx3.gui.Template
Provides template related services to the base template class, jsx3.gui.Template.Block.
jsx3.gui.Template.Block
Provides base class for creating custom GUI classes.
jsx3.gui.TextBox
This jsx3.gui.TextBox class allows integration of a standard HTML text input into the JSX DOM.
jsx3.gui.TimePicker
A form element that allows for the selection of an arbitrary time of day.
jsx3.gui.ToolbarButton
Renders a toolbar button.
jsx3.gui.Tree
Creates a DHTML-based navigational trees (similar to the tree structure used by Windows Explorer with folders and files).
jsx3.gui.Window
Allows for rendering a branch of the DOM of an application in a separate browser window.
jsx3.gui.WindowBar
jsx3.gui.WindowBar instances are used as the captionbar for JSXDialog and JSXAlert instances.

jsx3.gui

interface Alerts

jsx3.gui.Alerts

All Known Implementing Classes:

jsx3.app.Server, jsx3.gui.Dialog

abstract interface Alerts
Mixin interface allows implementors to show alerts, confirms, and prompts.

Since:

3.0

Method Summary
jsx3.gui.Dialog
alert(strTitle : String, strMessage : String, fctOnOk : Function, strOk : String, objParams : Object)
Shows an alert dialog.
protected void
configureAlert(objDialog : jsx3.gui.Dialog, objParams : Object)
Configures the alert dialog.
jsx3.gui.Dialog
confirm(strTitle : String, strMessage : String, fctOnOk : Function, fctOnCancel : Function, strOk : String, strCancel : String, intBtnDefault : int, fctOnNo : Function, strNo : String, objParams : Object)
Shows a confirm alert.
protected abstract jsx3.app.Model
implementors of this mixin interface must implement this method
jsx3.gui.Dialog
prompt(strTitle : String, strMessage : String, fctOnOk : Function, fctOnCancel : Function, strOk : String, strCancel : String, objParams : Object)
Shows an input prompt alert.
Method Detail

alert

jsx3.gui.Dialog alert(strTitle : String, strMessage : String, fctOnOk : Function, strOk : String, objParams : Object)
Shows an alert dialog.

Parameters:

strTitlethe title of the dialog
strMessagethe message to display
fctOnOkcallback function on pressing ok button, receives the dialog as an argument; if null the dialog will close itself; if defined must explicitly close the dialog
strOkthe text of the ok button, can be false to remove button from display
objParamsargument to configureAlert()

Returns:

 

See Also:


configureAlert

protected void configureAlert(objDialog : jsx3.gui.Dialog, objParams : Object)
Configures the alert dialog.

Parameters:

objDialogthe dialog
objParamsmay include fields 'width' {int}, 'height' {int}, 'noTitle' {boolean}, and 'nonModal' {boolean}.

confirm

jsx3.gui.Dialog confirm(strTitle : String, strMessage : String, fctOnOk : Function, fctOnCancel : Function, strOk : String, strCancel : String, intBtnDefault : int, fctOnNo : Function, strNo : String, objParams : Object)
Shows a confirm alert.

Parameters:

strTitlethe title of the dialog
strMessagethe message to display
fctOnOkcallback function on pressing ok button, receives the dialog as an argument; if null the dialog will close itself; if defined must explicitly close the dialog
fctOnCancelcallback function on pressing cancel button, receives the dialog as an argument; if null the dialog will close itself; if defined must explicitly close the dialog
strOkthe text of the ok button
strCancelthe text of the cancel button
intBtnDefaultthe bold button that receives return key, 1:ok, 2:cancel, 3:no
fctOnNocallback function on pressing no button, receives the dialog as an argument; if null the dialog will close itself; if defined must explicitly close the dialog
strNothe text of the no button
objParamsargument to configureAlert()

Returns:

 

See Also:


getAlertsParent

protected abstract jsx3.app.Model getAlertsParent()
implementors of this mixin interface must implement this method

Returns:

the parent of the alert dialogs 

prompt

jsx3.gui.Dialog prompt(strTitle : String, strMessage : String, fctOnOk : Function, fctOnCancel : Function, strOk : String, strCancel : String, objParams : Object)
Shows an input prompt alert.

Parameters:

strTitlethe title of the dialog
strMessagethe message to display
fctOnOkcallback function on pressing ok button, receives the dialog as an argument, and the value of the text input as a second argument; if null the dialog will close itself; if defined must explicitly close the dialog
fctOnCancelcallback function on pressing cancel button, receives the dialog as an argument; if null the dialog will close itself; if defined must explicitly close the dialog
strOkthe text of the ok button
strCancelthe text of the cancel button
objParamsargument to configureAlert()

Returns:

 

See Also:


jsx3.gui

class Block

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.ChartComponent, jsx3.gui.BlockX, jsx3.gui.Button, jsx3.gui.CDF, jsx3.gui.CheckBox, jsx3.gui.ColorPicker, jsx3.gui.Column, jsx3.gui.DatePicker, jsx3.gui.Dialog, jsx3.gui.DojoWidget, jsx3.gui.IFrame, jsx3.gui.Image, jsx3.gui.ImageButton, jsx3.gui.LayoutGrid, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Matrix.Column, jsx3.gui.Menu, jsx3.gui.RadioButton, jsx3.gui.Select, jsx3.gui.Slider, jsx3.gui.Splitter, jsx3.gui.Stack, jsx3.gui.Tab, jsx3.gui.TabbedPane, jsx3.gui.Table, jsx3.gui.Template.Block, jsx3.gui.TextBox, jsx3.gui.TimePicker, jsx3.gui.ToolbarButton, jsx3.gui.Tree, jsx3.gui.WindowBar, jsx3.vector.Block

class Block
extends jsx3.gui.Painted
This class provides a container-based, object-oriented approach to creating static html objects (basically this class creates "DIV" objects). This class is useful for creating objects as simple as 'labels' that can be placed anywhere on the screen. The advantage to using this class instead of trying to insert static html in the html window is that it allows the given HTML string to be managed by the 'container-management' strategy employed by the JSX Architecture

Field Summary
static int
0
static String
center
static String
left (default)
static String
right
static String
jsx30block
static String
#000000
static String
Verdana
static int
10
static String
span
static String
 
static String
[empty string] (default)
static String
none
static String
bold
static String
normal (default)
static int
Deprecated.
static int
3 (default)
static int
2
static int
1
static int
1 (default)
static int
Deprecated.
static String
JSX/images/spc.gif
static String
hidden
static String
[empty string] (default)
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strHTML : String)
instance initializer
Method Summary
String
Returns valid CSS property value for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat;
String
Returns valid CSS property value, (e.g.
String
Returns CSS property value(s) for a border (border: solid 1px #000000)
void
Returns the named attribute on the CDF record to which this object is mapped.
void
Returns the CDF ID of the record to map to.
String
Returns CSS text to override the standard instance properties on the painted object.
String
Returns the named CSS rule(s) to apply to the painted object.
String
Returns valid CSS property value, (e.g.
String
Returns valid CSS property value, (e.g.
Array<int>
Returns the dimensions in an array of four int values
String
Returns the CSS display for the object; one of jsx3.gui.Block.DISPLAYNONE (display:none;) and jsx3.gui.Block.DISPLAYBLOCK (display:;)
String
Returns the CSS font-family for the object
int
Returns the CSS font-size for the object
String
Returns the CSS font-weight for the object ("bold" or "normal")
int | String
Returns the height property of this object.
int
Returns IE tab index for setting the tabIndex property for the on-screen DHTML for the object
static jsx3.gui.Block
Deprecated. Use jsx3.html.getJSXParent() instead.
int | String
Returns the left property of this object.
String
Returns CSS property value(s) for a margin (margin:4px;)
int
Returns the overflow property for the object, that defines how its on-screen view will behave when its contents are larger than its specified width and/or height
String
Returns CSS property value(s) for a padding (padding:4px;)
int
Returns if the instance is relatively positioned on-screen; returns one of: jsx3.gui.Block.ABSOLUTE jsx3.gui.Block.RELATIVE
String
Returns HTML tag name to use when rendering the object on-screen (span is the default); if the property is null, jsx3.gui.Block.DEFAULTTAGNAME is used;
String
Returns the text/HTML for the control to be displayed on-screen; returns an empty string if null; since the text is rendered on-screen as browser-native HTML, the equivalent of an empty tag (e.g.
String
Returns the CSS text-align property for the object; if no property value exists, jsx3.gui.Block.ALIGNLEFT is returned by default
String
Returns the tooltip text to display when the object is hovered over.
int | String
Returns the top property of this object.
static String
Deprecated.
String
Returns the visibility property for the object
int | String
Returns the width property of this object.
int
Returns the CSS z-index property
void
Removes the "blocking" mask inside the block to stop user interactions with existing content
String
paint(strData : String)
Returns the DHTML, used for this object's on-screen view
jsx3.gui.Block
Sets valid CSS property value for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setBackgroundColor(strColor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g.
jsx3.gui.Block
setBorder(strCSS : String, bUpdateView : boolean)
Sets CSS property value(s) for a border (border: solid 1px #000000).
void
setCDFAttribute(strAttName : String)
Sets the named attribute on the CDF record to which this object is mapped.
void
setCDFId(strCDFId : String)
Sets the CDF ID of the record to map to.
jsx3.gui.Block
Sets CSS text to override the standard instance properties on the painted object.
jsx3.gui.Block
setClassName(strClassName : String)
Sets the named CSS rule(s) to apply to the painted object.
jsx3.gui.Block
setColor(strColor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g.
void
setCursor(strCursor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g.
void
setDimensions(left : int | String | Array<int | String>, top : int | String, width : int | String, height : int | String, bUpdateView : boolean)
Set one to four dimensions at once.
jsx3.gui.Block
setDisplay(DISPLAY : String, bUpdateView : boolean)
Sets the display for the object.
jsx3.gui.Block
setFontName(strFontName : String)
Sets the CSS font-family for the object; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setFontSize(intPixelSize : int)
Sets the CSS font-size for the object; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setFontWeight(FONTWEIGHT : String)
Sets the CSS font-weight for the object ("bold" or "normal"); returns reference to self to facilitate method chaining;
jsx3.gui.Block
setHeight(vntHeight : int | String, bUpdateView : boolean)
Sets the height property of this object.
jsx3.gui.Block
setIndex(intIndex : int, bUpdateView : boolean)
Sets IE tab index for setting the tabIndex property for the on-screen DHTML for the object; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setLeft(vntLeft : int | String, bUpdateView : boolean)
Sets the left property of this object.
jsx3.gui.Block
setMargin(strCSS : String, bUpdateView : boolean)
Sets CSS property value for margin.
jsx3.gui.Block
setOverflow(OVERFLOW : int)
Sets the overflow property for the object, that defines how its on-screen view will behave when its contents are larger than its specified width and/or height; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setPadding(strCSS : String, bUpdateView : boolean)
Sets the CSS property value for padding an object.
jsx3.gui.Block
setRelativePosition(intRelative : int, bUpdateView : boolean)
Sets if the jsx3.gui.Block instance is relatively positioned on-screen; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setTagName(strTagName : String)
Sets HTML tag name to use when rendering the object on-screen (jsx3.gui.Block.DEFAULTTAGNAME is the default); returns reference to self to facilitate method chaining;
jsx3.gui.Block
setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setTextAlign(ALIGN : String)
Sets the CSS text-align property for the object; returns reference to self to facilitate method chaining;
jsx3.gui.Block
setTip(strTip : String)
Sets the tooltip text to display when the object is hovered over; updates the model and the view immediately.
jsx3.gui.Block
setTop(vntTop : int | String, bUpdateView : boolean)
Sets the top property of this object.
void
setVisibility(VISIBILITY : String, bUpdateView : boolean)
Sets the CSS visibility property the object
jsx3.gui.Block
setWidth(vntWidth : int | String, bUpdateView : boolean)
Sets the width property of this object.
void
setZIndex(intZIndex : int, bUpdateView : boolean)
Sets the CSS z-index for the object
void
showMask(strMessage : String)
Displays a "blocking mask" inside the block to stop user interactions with content within the block.
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ABSOLUTE

static final int ABSOLUTE
0

ALIGNCENTER

static final String ALIGNCENTER
center

ALIGNLEFT

static final String ALIGNLEFT
left (default)

ALIGNRIGHT

static final String ALIGNRIGHT
right

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30block

DEFAULTCOLOR

static String DEFAULTCOLOR
#000000

DEFAULTFONTNAME

static String DEFAULTFONTNAME
Verdana

DEFAULTFONTSIZE

static int DEFAULTFONTSIZE
10

DEFAULTTAGNAME

static String DEFAULTTAGNAME
span

DEFAULTTEXT

static String DEFAULTTEXT
&#160;

DISPLAYBLOCK

static final String DISPLAYBLOCK
[empty string] (default)

DISPLAYNONE

static final String DISPLAYNONE
none

FONTBOLD

static final String FONTBOLD
bold

FONTNORMAL

static final String FONTNORMAL
normal (default)

NULLSTYLE

static int NULLSTYLE
Deprecated.
-1

OVERFLOWEXPAND

static final int OVERFLOWEXPAND
3 (default)

OVERFLOWHIDDEN

static final int OVERFLOWHIDDEN
2

OVERFLOWSCROLL

static final int OVERFLOWSCROLL
1

RELATIVE

static final int RELATIVE
1 (default)

SCROLLSIZE

static int SCROLLSIZE
Deprecated.
16

SPACE

static String SPACE
JSX/images/spc.gif

VISIBILITYHIDDEN

static final String VISIBILITYHIDDEN
hidden

VISIBILITYVISIBLE

static final String VISIBILITYVISIBLE
[empty string] (default)
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strHTML : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
strHTMLText/HTML markup to place in the jsx3.gui.Block instance
Method Detail

getBackground

String getBackground()
Returns valid CSS property value for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat;

Returns:

valid CSS property for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat;  

getBackgroundColor

String getBackgroundColor()
Returns valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))

Returns:

valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))  

getBorder

String getBorder()
Returns CSS property value(s) for a border (border: solid 1px #000000)

Returns:

 

getCDFAttribute

void getCDFAttribute()
Returns the named attribute on the CDF record to which this object is mapped.

getCDFId

void getCDFId()
Returns the CDF ID of the record to map to.

getCSSOverride

String getCSSOverride()
Returns CSS text to override the standard instance properties on the painted object.

Returns:

CSS text  

getClassName

String getClassName()
Returns the named CSS rule(s) to apply to the painted object.

Returns:

 

getColor

String getColor()
Returns valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))

Returns:

valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))  

getCursor

String getCursor()
Returns valid CSS property value, (e.g., default,wait,col-resize); if no value or an empty string, null is returned

Returns:

valid CSS property value, (e.g., default,wait,col-resize)  

getDimensions

Array<int> getDimensions()
Returns the dimensions in an array of four int values

Returns:

[left,top,width,height]  

getDisplay

String getDisplay()
Returns the CSS display for the object; one of jsx3.gui.Block.DISPLAYNONE (display:none;) and jsx3.gui.Block.DISPLAYBLOCK (display:;)

Returns:

 

getFontName

String getFontName()
Returns the CSS font-family for the object

Returns:

valid CSS font-family property value  

getFontSize

int getFontSize()
Returns the CSS font-size for the object

Returns:

font-size (in pixels)  

getFontWeight

String getFontWeight()
Returns the CSS font-weight for the object ("bold" or "normal")

Returns:

[jsx3.gui.Block.FONTBOLD. jsx3.gui.Block.FONTNORMAL]  

getHeight

int | String getHeight()
Returns the height property of this object.

Returns:

height.  

getIndex

int getIndex()
Returns IE tab index for setting the tabIndex property for the on-screen DHTML for the object

Returns:

 

getJSXParent

static jsx3.gui.Block getJSXParent(objGUI : HTMLElement)
Deprecated. Use jsx3.html.getJSXParent() instead.
Returns the first JSX parent (as a JSX instance in the model) of @objGUI (an HTML element in the view); returns null if no jsx parent could be found

Parameters:

objGUIHTML element in the view from which to begin looking for the first containing JSX parent in the model

Returns:

JSX object 

getLeft

int | String getLeft()
Returns the left property of this object.

Returns:

left.  

getMargin

String getMargin()
Returns CSS property value(s) for a margin (margin:4px;)

Returns:

 

getOverflow

int getOverflow()
Returns the overflow property for the object, that defines how its on-screen view will behave when its contents are larger than its specified width and/or height

Returns:

[jsx3.gui.Block.OVERFLOWSCROLL, jsx3.gui.Block.OVERFLOWHIDDEN, jsx3.gui.Block.OVERFLOWEXPAND]  

getPadding

String getPadding()
Returns CSS property value(s) for a padding (padding:4px;)

Returns:

 

getRelativePosition

int getRelativePosition()
Returns if the instance is relatively positioned on-screen; returns one of: jsx3.gui.Block.ABSOLUTE jsx3.gui.Block.RELATIVE

Returns:

 

getTagName

String getTagName()
Returns HTML tag name to use when rendering the object on-screen (span is the default); if the property is null, jsx3.gui.Block.DEFAULTTAGNAME is used;

Returns:

valid HTML tag name  

getText

String getText()
Returns the text/HTML for the control to be displayed on-screen; returns an empty string if null; since the text is rendered on-screen as browser-native HTML, the equivalent of an empty tag (e.g., <span\>) would be an enclosing tag with an empty string (no content): <span></span>. To return null would be equivalent to <span>null</span>, which is not the same as <span/>

Returns:

 

getTextAlign

String getTextAlign()
Returns the CSS text-align property for the object; if no property value exists, jsx3.gui.Block.ALIGNLEFT is returned by default

Returns:

one of: jsx3.gui.Block.ALIGNLEFT, jsx3.gui.Block.ALIGNRIGHT, jsx3.gui.Block.ALIGNCENTER  

getTip

String getTip()
Returns the tooltip text to display when the object is hovered over.

Returns:

 

getTop

int | String getTop()
Returns the top property of this object.

Returns:

top.  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getVisibility

String getVisibility()
Returns the visibility property for the object

Returns:

[jsx3.gui.Block.VISIBILITYVISIBLE, jsx3.gui.Block.VISIBILITYHIDDEN]  

getWidth

int | String getWidth()
Returns the width property of this object.

Returns:

width.  

getZIndex

int getZIndex()
Returns the CSS z-index property

Returns:

 

hideMask

void hideMask()
Removes the "blocking" mask inside the block to stop user interactions with existing content

paint

String paint(strData : String)
Returns the DHTML, used for this object's on-screen view

Parameters:

strDataText/HTML markup that will replace value of getText() during paint—typically passed by subclass, JSXBlockX after it performs an XML/XSL merge to acquire its data; for memory management purposes, the data is not set via setText() and, instead, is passed as a temporary input parameter, as the object's model would contain the text for no reason

Returns:

DHTML  

Overrides:


setBackground

jsx3.gui.Block setBackground(strBG : String)
Sets valid CSS property value for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat; returns reference to self to facilitate method chaining;

Parameters:

strBGvalid CSS property value for the background such as: background-image:url(x.gif); or background-image:url(x.gif);background-repeat:no-repeat;

Returns:

this object  

setBackgroundColor

jsx3.gui.Block setBackgroundColor(strColor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0)); returns reference to self to facilitate method chaining;

Parameters:

strColorvalid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object  

setBorder

jsx3.gui.Block setBorder(strCSS : String, bUpdateView : boolean)
Sets CSS property value(s) for a border (border: solid 1px #000000). Properties can be strung together as in: border:solid 1px #989885;border-left-width:0px;

Parameters:

strCSSvalid CSS property value for a border (border: solid 1px #000000)
bUpdateViewif true, the view will be updated with requiring a repaint

Returns:

this object  

setCDFAttribute

void setCDFAttribute(strAttName : String)
Sets the named attribute on the CDF record to which this object is mapped. Updates to show the new mapped value

Parameters:

strAttName

setCDFId

void setCDFId(strCDFId : String)
Sets the CDF ID of the record to map to. Updates to show the new mapped value

Parameters:

strCDFIdIf not set, the CDF Id used by the nearest ancestor of type jsx3.gui.CDF will be used.

setCSSOverride

jsx3.gui.Block setCSSOverride(strCSS : String)
Sets CSS text to override the standard instance properties on the painted object. Convenience method for extending this object. CSS properties affecting layout, including border-width, padding, margin, width, and height are strongly discouraged, as they may interfere with the framework's internal box models. Since some controls are composited from multiple HTML elements, some styles may not cascade to nested elements. Instance Properties are the preferred method for applying styles.

Parameters:

strCSSCSS text. For example, color:red;background-color:orange;

Returns:

this object  

setClassName

jsx3.gui.Block setClassName(strClassName : String)
Sets the named CSS rule(s) to apply to the painted object. Rules that specify border-width, padding, margin, width, and height are strongly discouraged. Multiple rules may be specified, delimited with a space. For example, label emphasis. Since some controls are composited from multiple HTML elements, some rule styles may not cascade to nested elements. Dynamic Properties are the preferred method for applying global styles.

Parameters:

strClassNameCSS property name without the leading "."

Returns:

this object  

setColor

jsx3.gui.Block setColor(strColor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g., red, #ffffff, rgb(255,0,0)); returns reference to self to facilitate method chaining;

Parameters:

strColorvalid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object  

setCursor

void setCursor(strCursor : String, bUpdateView : boolean)
Sets valid CSS property value, (e.g., default,wait,col-resize)

Parameters:

strCursorvalid CSS property value, (e.g., default,wait,col-resize)
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

setDimensions

void setDimensions(left : int | String | Array<int | String>, top : int | String, width : int | String, height : int | String, bUpdateView : boolean)
Set one to four dimensions at once. This operation is more efficient than calling more than one of setLeft, setTop, etc. Any argument can be null to indicate not to update it.

Parameters:

leftthe new left value or an array containing all four new values
topthe new top value
widththe new width value
heightthe new height value
bUpdateViewwhether to update the display of this object immediately. If left is an Array then this parameter is the second parameter passed to this method.

setDisplay

jsx3.gui.Block setDisplay(DISPLAY : String, bUpdateView : boolean)
Sets the display for the object. Note that although the framework uses CSS to apply this setting, the actual values that get set are determined by the system. Only those parameters listed for @DISPLAY are supported as inputs to this function.

Parameters:

DISPLAYone of jsx3.gui.Block.DISPLAYNONE or jsx3.gui.Block.DISPLAYBLOCK
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object  

setFontName

jsx3.gui.Block setFontName(strFontName : String)
Sets the CSS font-family for the object; returns reference to self to facilitate method chaining;

Parameters:

strFontNamevalid CSS font-family property value

Returns:

this object  

setFontSize

jsx3.gui.Block setFontSize(intPixelSize : int)
Sets the CSS font-size for the object; returns reference to self to facilitate method chaining;

Parameters:

intPixelSizefont-size (in pixels)

Returns:

this object  

setFontWeight

jsx3.gui.Block setFontWeight(FONTWEIGHT : String)
Sets the CSS font-weight for the object ("bold" or "normal"); returns reference to self to facilitate method chaining;

Parameters:

FONTWEIGHT[jsx3.gui.Block.FONTBOLD. jsx3.gui.Block.FONTNORMAL]

Returns:

this object  

setHeight

jsx3.gui.Block setHeight(vntHeight : int | String, bUpdateView : boolean)
Sets the height property of this object.

Parameters:

vntHeightthe height as a non-negative integer or non-negative percentage. For example: 45%, 12.
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object.  

setIndex

jsx3.gui.Block setIndex(intIndex : int, bUpdateView : boolean)
Sets IE tab index for setting the tabIndex property for the on-screen DHTML for the object; returns reference to self to facilitate method chaining;

Parameters:

intIndexany value in the valid range of -32767 to 32767
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object  

setLeft

jsx3.gui.Block setLeft(vntLeft : int | String, bUpdateView : boolean)
Sets the left property of this object. The left property specifies the horizontal offset of this object from its parent and only applies if this object is absolutely positioned.

Parameters:

vntLeftthe left value. Only numeric values and percentages are supported. For example: 25, -10, 20%.
bUpdateViewif @vntLeft is in integer (a number with no modifier) and @bUpdateView is true, the object's on-screen view is immediately updated to match its model, obviating the need to call '[object].repaint()'

Returns:

this object.  

setMargin

jsx3.gui.Block setMargin(strCSS : String, bUpdateView : boolean)
Sets CSS property value for margin.

Parameters:

strCSSThe preferred method to set margin is by moving clockwise, beginning with the north compass position, without the pixel designation. For example, to specify a top margin of 8 pixels, use 8 0 0 0. CSS syntax is supported, but requires that pixels be designated. For example, using margin:5px;margin-left:10px;, is equivalent to 5 5 5 10.
bUpdateViewif true, the view will be updated with requiring a repaint

Returns:

this object  

setOverflow

jsx3.gui.Block setOverflow(OVERFLOW : int)
Sets the overflow property for the object, that defines how its on-screen view will behave when its contents are larger than its specified width and/or height; returns reference to self to facilitate method chaining;

Parameters:

OVERFLOW[jsx3.gui.Block.OVERFLOWSCROLL, jsx3.gui.Block.OVERFLOWHIDDEN, jsx3.gui.Block.OVERFLOWEXPAND]

Returns:

this object  

setPadding

jsx3.gui.Block setPadding(strCSS : String, bUpdateView : boolean)
Sets the CSS property value for padding an object.

Parameters:

strCSSThe preferred method to set padding is by moving clockwise, beginning with the north compass position, without the pixel designation. For example, to specify a top padding of 8 pixels, use 8 0 0 0. CSS syntax is supported, but requires that pixels be designated. For example, using padding:5px;padding-left:10px;, is equivalent to 5 5 5 10.
bUpdateViewif true, the view will be updated without requiring a repaint.

Returns:

this object.  

setRelativePosition

jsx3.gui.Block setRelativePosition(intRelative : int, bUpdateView : boolean)
Sets if the jsx3.gui.Block instance is relatively positioned on-screen; returns reference to self to facilitate method chaining;

Parameters:

intRelativejsx3.gui.Block.RELATIVE will be applied to the view if null. One of: jsx3.gui.Block.RELATIVE jsx3.gui.Block.ABSOLUTE
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object  

setTagName

jsx3.gui.Block setTagName(strTagName : String)
Sets HTML tag name to use when rendering the object on-screen (jsx3.gui.Block.DEFAULTTAGNAME is the default); returns reference to self to facilitate method chaining;

Parameters:

strTagNamevalid HTML tag name (span, div, form, ol, ul, li, etc); if null is passed, the getter will use jsx3.gui.Block.DEFAULTTAGNAME

Returns:

this object  

setText

jsx3.gui.Block setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;

Parameters:

strTexttext/HTML
bRepaintif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

 

setTextAlign

jsx3.gui.Block setTextAlign(ALIGN : String)
Sets the CSS text-align property for the object; returns reference to self to facilitate method chaining;

Parameters:

ALIGNone of: jsx3.gui.Block.ALIGNLEFT, jsx3.gui.Block.ALIGNRIGHT, jsx3.gui.Block.ALIGNCENTER

Returns:

 

setTip

jsx3.gui.Block setTip(strTip : String)
Sets the tooltip text to display when the object is hovered over; updates the model and the view immediately. Note that the tip text is rendered natively by the browser and that the behavior may vary between browsers. Some browsers may honor line breaks in the text and some may have a maximum length that then show before truncating the tip. For more consistent rendering across browsers use the SPYGLASS event instead.

Parameters:

strTipthe tip text.

Returns:

this object.  

setTop

jsx3.gui.Block setTop(vntTop : int | String, bUpdateView : boolean)
Sets the top property of this object. The top property specifies the vertical offset of this object from its parent and only applies if this object is absolutely positioned.

Parameters:

vntTopthe top value. Only numeric values and percentages are supported. For example: 25, -10, 20%.
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object.  

setVisibility

void setVisibility(VISIBILITY : String, bUpdateView : boolean)
Sets the CSS visibility property the object

Parameters:

VISIBILITY[jsx3.gui.Block.VISIBILITYVISIBLE, jsx3.gui.Block.VISIBILITYHIDDEN]
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

setWidth

jsx3.gui.Block setWidth(vntWidth : int | String, bUpdateView : boolean)
Sets the width property of this object.

Parameters:

vntWidththe width as non-negative integer or non-negative percentage. For example: 45%, 12.
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

this object.  

setZIndex

void setZIndex(intZIndex : int, bUpdateView : boolean)
Sets the CSS z-index for the object

Parameters:

intZIndexz-index value
bUpdateViewif true, the view of this object is immediately updated, obviating the need to call repaint().

showMask

void showMask(strMessage : String)
Displays a "blocking mask" inside the block to stop user interactions with content within the block. Applies only to Blocks. Use only on blocks with no padding and with overflow set to hidden.

Parameters:

strMessagetext/message to display in the blocking mask to tell the user it is disabled

jsx3.gui

class BlockX

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.BlockX

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.Cacheable

class BlockX
extends jsx3.gui.Block
Paints the result of an XSL transformation in an Block. A transformation is performed on the XML source document with the XSL source document. The result is serialized HTML, which is painted to screen.

Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String)
instance initializer
Method Summary
static String
Deprecated.
String
Returns the XSL string of this object.
String
Returns the XSL URL of this object.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.xml.Cacheable
setXSLString(strXSL : String)
Sets the XSL string of this object.
jsx3.xml.Cacheable
setXSLURL(strXSLURL : String)
Sets the XSL URL of this object.
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXmlAsync, setXmlBind
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
Method Detail

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getXSLString

String getXSLString()
Returns the XSL string of this object.

Returns:

 

Overrides:


getXSLURL

String getXSLURL()
Returns the XSL URL of this object.

Returns:

 

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setXSLString

jsx3.xml.Cacheable setXSLString(strXSL : String)
Sets the XSL string of this object.

Parameters:

strXSL

Returns:

this object.  

Overrides:


setXSLURL

jsx3.xml.Cacheable setXSLURL(strXSLURL : String)
Sets the XSL URL of this object.

Parameters:

strXSLURL

Returns:

this object.  

Overrides:


jsx3.gui

class Button

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Button

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Button
extends jsx3.gui.Block
Provides a object-oriented interface for a standard command button.

This class publishes the following model events:

Field Summary
static String
#e8e8f5
static String
jsx30button
static int
18
static String
#f6f6ff
static String
#a6a6af
Constructor Summary
void
init(strName : String, intLeft : int, intTop : int, intWidth : int, strText : String)
instance initializer
Method Summary
void
Deprecated. use doExecute() instead
void
Invokes the EXECUTE model event of this button.
int
Sets the validation state for the button and returns the validation state; always returns jsx3.gui.Form.STATEVALID (as buttons can only be valid)
String
Because it implements the jsx3.gui.Form class, the jsx3.gui.Button class implements various form-related methods (validate, getValue, disable, etc); in the case of 'getValue', this method will return the button's text (caption)
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen view.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState, setValue
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#e8e8f5

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30button

DEFAULTHEIGHT

static int DEFAULTHEIGHT
18

DEFAULTHIGHLIGHT

static String DEFAULTHIGHLIGHT
#f6f6ff

DEFAULTSHADOW

static String DEFAULTSHADOW
#a6a6af
Constructor Detail

init

void init(strName : String, intLeft : int, intTop : int, intWidth : int, strText : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
intLeftleft position (in pixels) of the object relative to its parent container; not required if button is one of: jsx3.gui.Button.SYSTEMOPEN, jsx3.gui.Button.DIALOGCLOSE, jsx3.gui.Button.DIALOGALPHA, jsx3.gui.Button.DIALOGSHADE
intToptop position (in pixels) of the object relative to its parent container; not required if button is one of: jsx3.gui.Button.SYSTEMOPEN, jsx3.gui.Button.DIALOGCLOSE, jsx3.gui.Button.DIALOGALPHA, jsx3.gui.Button.DIALOGSHADE
intWidthwidth (in pixels) of the object; not required if button is one of: jsx3.gui.Button.SYSTEMOPEN, jsx3.gui.Button.DIALOGCLOSE, jsx3.gui.Button.DIALOGALPHA, jsx3.gui.Button.DIALOGSHADE
strTexttext to display in the given button; if null JSXTABLEHEADERCELL.DEFAULTTEXT is used
Method Detail

doClick

void doClick()
Deprecated. use doExecute() instead
call to fire the execute event for the button; fires any bound 'jsxexecute' event (jsx3.gui.Interactive.EXECUTE)

See Also:


doExecute

void doExecute(objEvent : jsx3.gui.Event)
Invokes the EXECUTE model event of this button. Note that because the model event is invoked programmatically rather than by user interaction the objEVENT event parameter will be null if the objEvent parameter is undefined.

Parameters:

objEventthe browser event that caused the execution of this button. This argument is optional and should only be provided if the execute of this button is the result of a browser event. This parameter will be passed along to the model event as objEVENT.

doValidate

int doValidate()
Sets the validation state for the button and returns the validation state; always returns jsx3.gui.Form.STATEVALID (as buttons can only be valid)

Returns:

jsx3.gui.Form.STATEVALID  

Overrides:


getValue

String getValue()
Because it implements the jsx3.gui.Form class, the jsx3.gui.Button class implements various form-related methods (validate, getValue, disable, etc); in the case of 'getValue', this method will return the button's text (caption)

Returns:

 

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen view.

Returns:

DHTML  

Overrides:


jsx3.gui

class CDF

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.CDF

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class CDF
extends jsx3.gui.Block
Provides a container that maps to a CDF Document in the cache. This provides a simplified mechanism for mapping forms and blocks to CDF Documents in the XML Cache. Instances of this class can nest to point to another CDF record in the same document or can point to a CDF document of their own.

Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
String
Returns the CDF ID of the record to map to.
void
read(bRepaint : boolean, strRecordId : String)
Updates all mapped descendants with values from the source CDF Document
void
redrawRecord(strRecordId : String, intAction : int)
No-op.
void
setCDFId(strCDFId : String)
Sets the CDF ID of the record to map to.
void
Updates the source CDF document with values returned from mapped descendants
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource, resetData
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

getCDFId

String getCDFId()
Returns the CDF ID of the record to map to.

Returns:

 

Overrides:


read

void read(bRepaint : boolean, strRecordId : String)
Updates all mapped descendants with values from the source CDF Document

Parameters:

bRepaintif false no repaint will be applied when setting text or values
strRecordIdIf set, only those descendants that map to this specific CDF record will be updated.

redrawRecord

void redrawRecord(strRecordId : String, intAction : int)
No-op.

Parameters:

strRecordIdthe jsxid attribute of the data record to redraw.
intActionINSERT, UPDATE, or DELETE.

Overrides:


setCDFId

void setCDFId(strCDFId : String)
Sets the CDF ID of the record to map to. Updates all mapped descendants with values from the newly created mapping.

Parameters:

strCDFIdIf not set, the CDF Id used by the nearest ancestor of type jsx3.gui.CDF will be used.

Overrides:


write

void write()
Updates the source CDF document with values returned from mapped descendants

jsx3.gui

class CheckBox

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.CheckBox

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class CheckBox
extends jsx3.gui.Block
This class is a wrapper of the standard HTML checkbox.

This class publishes the following model events:

Field Summary
static int
1: checked
static String
jsx30checkbox
static int
2: dashed
static int
0: unchecked (default)
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strText : String, CHECKED : int)
The instance initializer.
Method Summary
int
validates that the checkbox is checked if it is required (e.g.
int
Returns current state of checkbox; to get the state of the checkbox when it was first initialized, use: getDefaultChecked().
int
Returns state of checkbox when it was first initialized; to get the current state, use: getChecked();
int
Returns current state of checkbox; to get the state of the checkbox when it was first initialized, use: getDefaultChecked().
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.CheckBox
setChecked(intChecked : int)
Sets the state of this checkbox.
jsx3.gui.CheckBox
setDefaultChecked(CHECKED : int)
Sets state of checkbox when it is first initialized; returns reference to self
jsx3.gui.CheckBox
setValue(vntValue : String)
Sets the state of this checkbox.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

CHECKED

static final int CHECKED
1: checked

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30checkbox

PARTIAL

static final int PARTIAL
2: dashed

UNCHECKED

static final int UNCHECKED
0: unchecked (default)
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strText : String, CHECKED : int)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
strTexttext/HTML markup to display with the checkbox;
CHECKEDif jsx3.gui.CheckBox.CHECKED or null, checkbox is checked; if jsx3.gui.CheckBox.UNCHECKED checkbox is unchecked
Method Detail

doValidate

int doValidate()
validates that the checkbox is checked if it is required (e.g., [object].setRequired()); returns (as well as sets as a property on the object) one of: jsx3.gui.Form.STATEVALID jsx3.gui.Form.INSTATEVALID

Returns:

one of: jsx3.gui.Form.STATEVALID jsx3.gui.Form.INSTATEVALID  

Overrides:


getChecked

int getChecked()
Returns current state of checkbox; to get the state of the checkbox when it was first initialized, use: getDefaultChecked(). Default: jsx3.gui.CheckBox.CHECKED

Returns:

one of: jsx3.gui.CheckBox.CHECKED or jsx3.gui.CheckBox.UNCHECKED  

getDefaultChecked

int getDefaultChecked()
Returns state of checkbox when it was first initialized; to get the current state, use: getChecked();

Returns:

one of: jsx3.gui.CheckBox.CHECKED or jsx3.gui.CheckBox.UNCHECKED  

getValue

int getValue()
Returns current state of checkbox; to get the state of the checkbox when it was first initialized, use: getDefaultChecked(). Default: jsx3.gui.CheckBox.CHECKED

Returns:

one of: jsx3.gui.CheckBox.CHECKED or jsx3.gui.CheckBox.UNCHECKED  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setChecked

jsx3.gui.CheckBox setChecked(intChecked : int)
Sets the state of this checkbox. This method will execute the TOGGLE model event only under the deprecated 3.0 model event protocol.

Parameters:

intCheckedCHECKED or UNCHECKED

Returns:

this object 

See Also:

,

setDefaultChecked

jsx3.gui.CheckBox setDefaultChecked(CHECKED : int)
Sets state of checkbox when it is first initialized; returns reference to self

Parameters:

CHECKEDone of: jsx3.gui.CheckBox.CHECKED or jsx3.gui.CheckBox.UNCHECKED

Returns:

this object  

setValue

jsx3.gui.CheckBox setValue(vntValue : String)
Sets the state of this checkbox. This method calls setChecked.

Parameters:

vntValuecheckbox is not checked if value is "false" "0" or "null".

Returns:

this object  

Overrides:


jsx3.gui

class ColorPicker

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.ColorPicker

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class ColorPicker
extends jsx3.gui.Block
A GUI class that allows the user to pick a color using an HSB (hue-saturation-brightness) picker.

Since:

3.2

Field Summary
static int
Value for the axis property indicating a brightness axis.
static int
The default rendered height of this control if no height is specified.
static int
The default rendered width of this control if no width is specified.
static int
Value for the axis property indicating a hue axis.
static int
Value for the axis property indicating a saturation axis.
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int, vntHeight : int)
The instance initializer.
Method Summary
static Array<int>
HSBtoRGB(h : float, s : float, l : float)
Converts HSB color components to RGB components.
static Array<int>
RGBtoHSB(r : int, g : int, b : int)
Converts RGB color components to HSB components.
int
int
int
Returns the RGB value of the currently selected color as an integer.
int
Returns the RGB value of the currently selected color as an integer.
String
Returns the HTML to render this control.
jsx3.gui.ColorPicker
setAxis(intAxis : int)
Sets the color axis shown on the right side of the control.
void
setHSB(h : float, s : float, b : float)
Sets the currently selected color by HSB components.
void
setRGB(rgb : int)
Sets the currently selected color by RGB.
void
setValue(strValue : int | String)
Sets the RGB value of this color picker.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

BRIGHTNESS

static final int BRIGHTNESS
Value for the axis property indicating a brightness axis.

DEFAULT_HEIGHT

static int DEFAULT_HEIGHT
The default rendered height of this control if no height is specified.

DEFAULT_WIDTH

static int DEFAULT_WIDTH
The default rendered width of this control if no width is specified.

HUE

static final int HUE
Value for the axis property indicating a hue axis.

SATURATION

static final int SATURATION
Value for the axis property indicating a saturation axis.
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int, vntHeight : int)
The instance initializer.

Parameters:

strName
vntLeft
vntTop
vntWidth
vntHeight
Method Detail

HSBtoRGB

static Array<int> HSBtoRGB(h : float, s : float, l : float)
Converts HSB color components to RGB components.

Parameters:

hThe hue component, [0.0, 1.0].
sThe saturation component, [0.0, 1.0].
lThe brightness component, [0.0, 1.0].

Returns:

[r, g, b]. Each component is an integer [0, 255].  

RGBtoHSB

static Array<int> RGBtoHSB(r : int, g : int, b : int)
Converts RGB color components to HSB components.

Parameters:

rThe red component, [0, 255]. If only one parameter is passed, this parameter may be a 24-bit integer of the form 0xRRGGBB.
gThe green component, [0, 255].
bThe blue component, [0, 255].

Returns:

[h, s, b]. Each component is a float [0.0, 1.0].  

doValidate

int doValidate()

Returns:

always jsx3.gui.Form.STATEVALID.  

Overrides:


getAxis

int getAxis()

Returns:

HUE, SATURATION, or BRIGHTNESS.  

getRGB

int getRGB()
Returns the RGB value of the currently selected color as an integer. The return value is a 24-bit number of the form 0xRRGGBB.

Returns:

 

getValue

int getValue()
Returns the RGB value of the currently selected color as an integer. The return value is a 24-bit number of the form 0xRRGGBB.

Returns:

 

Overrides:


paint

String paint()
Returns the HTML to render this control.

Returns:

 

Overrides:


setAxis

jsx3.gui.ColorPicker setAxis(intAxis : int)
Sets the color axis shown on the right side of the control. The other two axes are displayed in a box on the left side.

Parameters:

intAxisHUE, SATURATION, or BRIGHTNESS.

Returns:

 

See Also:

, ,

setHSB

void setHSB(h : float, s : float, b : float)
Sets the currently selected color by HSB components.

Parameters:

hThe hue component, [0.0, 1.0].
sThe saturation component, [0.0, 1.0].
bThe brightness component, [0.0, 1.0].

setRGB

void setRGB(rgb : int)
Sets the currently selected color by RGB. The view is updated to reflect the change in value.

Parameters:

rgba 24-bit integer of the form 0xRRGGBB.

setValue

void setValue(strValue : int | String)
Sets the RGB value of this color picker.

Parameters:

strValuethe supported formats are: RGB integer value as number or string and HTML hex code, "#000000".

Overrides:


jsx3.gui

class Column

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Column

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Column
extends jsx3.gui.Block
Deprecated. Use jsx3.gui.Matrix.Column instead.
Provides a way to generate a column of data for a jsx3.gui.List instance (or compatible subclass). It allows the developer to specify custom XSLT for more-complex output, custom edit masks for editable grids, sort types and sort paths and other series-related activities.

See Also:

jsx3.gui.Matrix.Column

Field Summary
static String
jsx30column_c3
static String
jsx30column_c1
static int
100
static int
0
static int
1 (default)
static void
Deprecated. Renamed to RESIZABLE.
static String
number
static String
text (default)
static String
middle
static String
top (default)
Constructor Summary
void
init(strName : String, strText : String, intWidth : int, strPath : String)
instance initializer
Method Summary
int
Returns whether the parent list/grid can be sorted on this column
String
Returns the data type for this column of data (affects sorting if this column is used for sorting the data); valid types include: jsx3.gui.Column.TYPETEXT and jsx3.gui.Column.TYPENUMBER
String
Returns name of JSX GUI object to use as the edit mask
String
Returns the selection path for this column of data.
int
Returns flag (jsx3.gui.Column.RESIZABLE or jsx3.gui.Column.FIXED) denoting whether or not the given column can be resized.
void
Deprecated. Renamed to getResizable.
String
Returns the selection path to use to sort this column.
String
Gets the vertical alignment for the header cell text.
static String
Deprecated.
int
Gets whether or not the header cell for this column should wrap its text when the column is too narrow to display truncate with an ellipsis.
String
getXSLString(strXSL : ?)
Returns XSLT fragment for any custom template to render the cells for this column.
String
paint(bBufferColumn : boolean, SORT_DIRECTION : String)
Returns the DHTML, used for this object's on-screen VIEW
String
updates the on-screen VIEW for the object.
jsx3.gui.Column
setCanSort(SORT : int)
Sets whether the parnet list/grid can be sorted on this column.
jsx3.gui.Column
setDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self
jsx3.gui.Column
setEditMask(strJSXName : String)
Sets name of JSX GUI object to use as the edit mask; can also can be the system-generated id assigned at object initialization; returns ref to self
jsx3.gui.Column
setPath(strPath : String)
Sets the selection path for this column of data.
jsx3.gui.Column
setResizable(RESIZE : int)
Sets flag (jsx3.gui.Column.RESIZABLE or jsx3.gui.Column.FIXED) denoting whether or not the given column can be resized.
void
Deprecated. Renamed to setResizable.
jsx3.gui.Column
setSortPath(strPath : String)
Sets the selection path to use to sort this column.
jsx3.gui.Column
setVAlign(VALIGN : String)
Sets the vertical alignment for the header cell text.
jsx3.gui.Column
setWrap(WRAP : int)
Sets whether or not the header cell for this column should wrap its text when the column is too narrow to display truncate with an ellipsis.
jsx3.gui.Column
setXSLString(strXSL : String)
binds an XSL document fragment (as string) as a property on the object, so that when the object is serialized the XSL is contained within.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTCELLCLASSGRID

static String DEFAULTCELLCLASSGRID
jsx30column_c3

DEFAULTCELLCLASSLIST

static String DEFAULTCELLCLASSLIST
jsx30column_c1

DEFAULTWIDTH

static int DEFAULTWIDTH
100

FIXED

static final int FIXED
0

RESIZABLE

static final int RESIZABLE
1 (default)

RESIZEABLE

static ? RESIZEABLE
Deprecated. Renamed to RESIZABLE.

TYPENUMBER

static final String TYPENUMBER
number

TYPETEXT

static final String TYPETEXT
text (default)

VALIGNMIDDLE

static String VALIGNMIDDLE
middle

VALIGNTOP

static String VALIGNTOP
top (default)
Constructor Detail

init

void init(strName : String, strText : String, intWidth : int, strPath : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
strTextlabel to appear in column header; can be valid DHTML
intWidthwidth (in pixels) of the object;
strPaththe selection path for this column of data. Typically this is simply the name of the attribute preceded by '@' (i.e., @jsxtext, @social, @phone, etc);
Method Detail

getCanSort

int getCanSort()
Returns whether the parent list/grid can be sorted on this column

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getDataType

String getDataType()
Returns the data type for this column of data (affects sorting if this column is used for sorting the data); valid types include: jsx3.gui.Column.TYPETEXT and jsx3.gui.Column.TYPENUMBER

Returns:

data type for this column's data  

getEditMask

String getEditMask()
Returns name of JSX GUI object to use as the edit mask

Returns:

name of the control  

getPath

String getPath()
Returns the selection path for this column of data. Typically this is simply the name of the attribute preceded by '@' (i.e., @jsxtext, @social, @phone, etc); returns '@jsxid' if no path specified

Returns:

selection path (xpath / xsl query)  

getResizable

int getResizable()
Returns flag (jsx3.gui.Column.RESIZABLE or jsx3.gui.Column.FIXED) denoting whether or not the given column can be resized. Default: jsx3.gui.Column.RESIZABLE

Returns:

 

getResizeable

void getResizeable()
Deprecated. Renamed to getResizable.

getSortPath

String getSortPath()
Returns the selection path to use to sort this column. If the sort path has not been set explicitly, this method returns the value of this.getPath().

Returns:

 

See Also:


getVAlign

String getVAlign()
Gets the vertical alignment for the header cell text. Default: jsx3.gui.Column.VALIGNTOP;

Returns:

one of: jsx3.gui.Column.VALIGNTOP or jsx3.gui.Column.VALIGNMIDDLE  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getWrap

int getWrap()
Gets whether or not the header cell for this column should wrap its text when the column is too narrow to display truncate with an ellipsis. Default: jsx3.Boolean.FALSE

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getXSLString

String getXSLString(strXSL : ?)
Returns XSLT fragment for any custom template to render the cells for this column.

Parameters:

strXSL

Returns:

valid XSLT document fragment to be inserted into the overall XSLT document for the list/grid parent  

paint

String paint(bBufferColumn : boolean, SORT_DIRECTION : String)
Returns the DHTML, used for this object's on-screen VIEW

Parameters:

bBufferColumnfalse if null; if true, the default xsl template for a buffer column cell is returned
SORT_DIRECTIONone of: jsx3.gui.List.SORTASCENDING or jsx3.gui.List.SORTDESCENDING

Returns:

DHTML  

Overrides:


repaint

String repaint()
updates the on-screen VIEW for the object. repaints both the head and body for the list/grid containing the column (colunns are composed of HTML TD elements that cannot be repainted individually)

Returns:

DHTML  

Overrides:


setCanSort

jsx3.gui.Column setCanSort(SORT : int)
Sets whether the parnet list/grid can be sorted on this column. Default: jsx3.Boolean.TRUE

Parameters:

SORTone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setDataType

jsx3.gui.Column setDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self

Parameters:

DATATYPEdata type for this column's data; ; valid types include: jsx3.gui.Column.TYPETEXT and jsx3.gui.Column.TYPENUMBER

Returns:

this object  

setEditMask

jsx3.gui.Column setEditMask(strJSXName : String)
Sets name of JSX GUI object to use as the edit mask; can also can be the system-generated id assigned at object initialization; returns ref to self

Parameters:

strJSXNameJSX name property for the control to use as the edit/input mask; also can be the system-generated id assigned at object initialization

Returns:

this object  

setPath

jsx3.gui.Column setPath(strPath : String)
Sets the selection path for this column of data. Typically this is simply the name of the attribute preceded by '@' (i.e., @jsxtext, @social, @phone, etc); returns a ref to self;

Parameters:

strPathselection path (xpath / xsl query)

Returns:

this object  

setResizable

jsx3.gui.Column setResizable(RESIZE : int)
Sets flag (jsx3.gui.Column.RESIZABLE or jsx3.gui.Column.FIXED) denoting whether or not the given column can be resized. Default: jsx3.gui.Column.RESIZABLE

Parameters:

RESIZEone of: jsx3.gui.Column.RESIZABLE or jsx3.gui.Column.FIXED

Returns:

this object  

setResizeable

void setResizeable()
Deprecated. Renamed to setResizable.

setSortPath

jsx3.gui.Column setSortPath(strPath : String)
Sets the selection path to use to sort this column. By setting the sort path property, a column may cause its list to be sorted according to data that is not necessarily the string displayed in the column.

Parameters:

strPath

Returns:

 

setVAlign

jsx3.gui.Column setVAlign(VALIGN : String)
Sets the vertical alignment for the header cell text. This does not affect the vertical alignment for the data rows.

Parameters:

VALIGNone of: jsx3.gui.Column.VALIGNTOP or jsx3.gui.Column.VALIGNMIDDLE

Returns:

this object  

setWrap

jsx3.gui.Column setWrap(WRAP : int)
Sets whether or not the header cell for this column should wrap its text when the column is too narrow to display truncate with an ellipsis.

Parameters:

WRAPone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setXSLString

jsx3.gui.Column setXSLString(strXSL : String)
binds an XSL document fragment (as string) as a property on the object, so that when the object is serialized the XSL is contained within. When this object is live, the XSL will be parsed and used to generate the on-screen VIEW for the object

Parameters:

strXSLif null or empty string is passed, any existing value is removed. Otherwise, must be XSLT fragment that will generate the content for a given TD (cell)

Returns:

this object  

jsx3.gui

class DatePicker

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.DatePicker

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class DatePicker
extends jsx3.gui.Block
A form element that allows for the selection of an arbitrary date by showing a navigable calendar.

This control is localized to the server locale. Users with computers set to other locales may see a version of the control appropriate for their locale.

This class uses the jsx3.util.DateFormat class to both format and parse dates. Dates are formatted before they are displayed in the text box of the date picker. Dates are parsed after a user manually changes the text in the text box. Parsing with DateFormat is fairly strict. If parsing fails, the value of the date picker is unchanged and the displayed value refreshes.

The calendar calculates dates in the time of the local machine, not UTC (Greenwich Mean Time). Date values chosen with the calendar are always 0h:00m local time.

Date pickers publish the following model events:

Since:

3.0

See Also:

jsx3.util.DateFormat,

Field Summary
static String
Deprecated. This value is now localized.
static int
Deprecated. This value is now localized.
Constructor Summary
void
init(strName : String, intLeft : int | String, intTop : int | String, intWidth : int | String, intHeight : int | String)
The instance initializer.
Method Summary
int
Returns STATEVALID if this date picker is not required or if it is required and its value is not null, otherwise returns STATEINVALID.
void
Shows the calendar for this date picker and places focus within the calendar as though the user had clicked on the show calendar button.
Date
Returns the current value of this form field as a JavaScript Date object.
int
Returns the jsxfirstweekday field
String | int
Returns the jsxformat field
String
getIcon(strDefault : String)
Returns the URL to use for the clickable image that triggers the calendar to display.
String
Returns the value of this form field (the string displayed in the text box).
String
void
setDate(date : Date)
Set the date value of this form field
void
setFirstDayOfWeek(jsxfirstweekday : int)
Sets the jsxfirstweekday field
void
setFormat(jsxformat : String | int)
Sets the format of this date picker.
void
setIcon(strPath : String)
Sets the URL to use for the clickable image that triggers the calendar to display.
jsx3.gui.DatePicker
setValue(vntValue : String | Date | int)
Sets the value of this date picker.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_FORMAT

static String DEFAULT_FORMAT
Deprecated. This value is now localized.
The default date format when none is specified for an instance of this class.

DEFAULT_WEEK_START

static int DEFAULT_WEEK_START
Deprecated. This value is now localized.
The default day of the start of a week when none is specified for an instance of this class. Sunday.
Constructor Detail

init

void init(strName : String, intLeft : int | String, intTop : int | String, intWidth : int | String, intHeight : int | String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
intLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
intTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
intWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
intHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
Method Detail

doValidate

int doValidate()
Returns STATEVALID if this date picker is not required or if it is required and its value is not null, otherwise returns STATEINVALID.

Returns:

 

Overrides:

See Also:

,

focusCalendar

void focusCalendar()
Shows the calendar for this date picker and places focus within the calendar as though the user had clicked on the show calendar button. The calendar hides automatically when focus leaves the calendar.

getDate

Date getDate()
Returns the current value of this form field as a JavaScript Date object.

Returns:

 

getFirstDayOfWeek

int getFirstDayOfWeek()
Returns the jsxfirstweekday field

Returns:

jsxfirstweekday  

getFormat

String | int getFormat()
Returns the jsxformat field

Returns:

jsxformat  

getIcon

String getIcon(strDefault : String)
Returns the URL to use for the clickable image that triggers the calendar to display.

Parameters:

strDefault

Returns:

 

Since:

3.7

getValue

String getValue()
Returns the value of this form field (the string displayed in the text box).

Returns:

 

Overrides:


paint

String paint()

Returns:

 

Overrides:


setDate

void setDate(date : Date)
Set the date value of this form field

Parameters:

datemay be null to clear the value of the form field

setFirstDayOfWeek

void setFirstDayOfWeek(jsxfirstweekday : int)
Sets the jsxfirstweekday field

Parameters:

jsxfirstweekdaythe new value for jsxfirstweekday

setFormat

void setFormat(jsxformat : String | int)
Sets the format of this date picker. The format should conform to the syntax of jsx3.util.DateFormat. The provided format may also be an integer, in which case it is intepreted as one of of the fields of DateFormat - SHORT, MEDIUM, LONG, or FULL - and the displayed format will be localized accordingly.

Parameters:

jsxformatthe new format.

See Also:


setIcon

void setIcon(strPath : String)
Sets the URL to use for the clickable image that triggers the calendar to display. If not provided, the default system image will be used. The recommended image size is 13 x 18 pixels.

Parameters:

strPathThis URL will be resolved relative to the project path.

Since:

3.7

setValue

jsx3.gui.DatePicker setValue(vntValue : String | Date | int)
Sets the value of this date picker. This method updates the view immediately.

Parameters:

vntValue

Returns:

this object  

Overrides:


jsx3.gui

class Dialog

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Dialog

All Implemented Interfaces:

jsx3.gui.Alerts, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Dialog
extends jsx3.gui.Block
Renders a dialog window. A dialog can contain other DOM objects; usually a dialog contains one child of type jsx3.gui.WindowBar and one child of type jsx3.gui.Block.

Field Summary
static String
#e8e8f5 (default)
static int
Enum value for the resizable property of instances of this class indicating a non-resizable dialog.
static int
Enum value for the windowState property of instances of this class indicating a maximized dialog.
static int
Enum value for the windowState property of instances of this class indicating a minimized dialog.
static int
Enum value for the modal property of instances of this class indicating a modal dialog.
static int
Enum value for the modal property of instances of this class indicating a non-modal dialog.
static int
Enum value for the resizable property of instances of this class indicating a resizable dialog.
static void
Deprecated. Renamed to RESIZABLE.
Constructor Summary
void
init(strName : String, vntWidth : int | String, vntHeight : int | String, strTitle : String)
instance initializer
Method Summary
jsx3.gui.Dialog
alerts the user's attention to the dialog box by making its caption bar 'flash' on-screen (as it typical with a windows modal dialog)
void
Modifies the top and left properties of this dialog in order to fit it within its parent container.
void
removes the dialog box from the JSX DOM and removes its on-screen VIEW from the browser DOM
void
Toggles the state of the dialog between 'maximized' and its 'initial state'
void
doToggleState(STATE : int)
typically called by minimize/windowshade jsx3.gui.ToolbarButton in the dialog box's caption bar; toggles the window's state between full-size and window-shaded (where only the dialog's caption bar is visible); or fully minimized to the application task bar if one exists
void
focus(bTimeout : boolean)
Applies focus to the caption bar if the dialog has one; otherwise the dialog is given focus.
Object<String, int>
Returns the absolute positioning of the object's on-screen view (specifically, the dialog box, not its modal container if there is one) in relation to JSXROOT (whose left/top is 0/0).
jsx3.gui.Block
Implements necessary method for the Alerts interface.
String
getBorder(strDefault : String)
Returns the outer border that surrounds the entire dialog.
int
getBuffer(strDefault : String)
Returns the uniform buffer that separates the dialog's content box, captionbar, and the outer dialog border.
jsx3.gui.WindowBar
Returns an object handle to the jsx3.gui.WindowBar instance associated with the jsx3.gui.Dialog instance
String
getContentBorder(strDefault : String)
Returns the border that surrounds the dialog content.
int
Returns whether a dialog displays as modal or not.
int
Returns whether the dialog can be resized or not.
jsx3.gui.ToolbarButton
Returns object handle to the jsx3.gui.ToolbarButton instance that resides in the application (this.getServer()) task bar and is associated with this dialog instance; returns null if none found
static String
Deprecated.
int
Returns state of the window (full-size / window-shaded).
int
Returns numeric multiplier for the dialog's z-index.
boolean
Returns whether this dialog instance is the front-most dialog among all open dialogs
String
Returns the HTML, used for this object's on-screen VIEW
void
paintChild(objJSX : jsx3.app.Model, bGroup : ?)
Ensures that HTML content is added to the correct VIEW element given the unique complexities of a the jsx3.gui.Dialog class
void
Removes the box model abstraction for a given object and its descendants.
void
setBorder(strCSS : String)
Sets the outer border that surrounds the entire dialog.
void
setBuffer(intBuffer : int)
Sets the uniform buffer that separates the dialog's content box, captionbar, and the outer dialog border.
void
Sets the border that surrounds the dialog content.
jsx3.gui.Dialog
setModal(intModal : int)
Sets whether a dialog displays as modal or not.
jsx3.gui.Dialog
setResize(RESIZE : int)
Sets whether the dialog box's on-screen view can be resized; returns reference to self to facilitate method chaining
jsx3.gui.Dialog
setResizeParameters(RESIZE : int, intMinX : int, intMinY : int, intMaxX : int, intMaxY : int, strAfterResizeFunction : ?)
Sets resize parameters such as min width, max width, etc for the dialog; returns reference to self to facilitate method chaining
jsx3.gui.Dialog
setWindowState(STATE : int)
Sets state of the window (full-size / window-shaded); returns ref to self for method chaining
jsx3.gui.Dialog
setZMultiplier(intMultiplier : int)
Sets numeric multiplier for the dialog's z-index.
Methods Inherited From jsx3.gui.Alerts
alert, configureAlert, confirm, prompt
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChildren, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#e8e8f5 (default)

FIXED

static final int FIXED
Enum value for the resizable property of instances of this class indicating a non-resizable dialog.

MAXIMIZED

static final int MAXIMIZED
Enum value for the windowState property of instances of this class indicating a maximized dialog.

MINIMIZED

static final int MINIMIZED
Enum value for the windowState property of instances of this class indicating a minimized dialog.

MODAL

static final int MODAL
Enum value for the modal property of instances of this class indicating a modal dialog.

NONMODAL

static final int NONMODAL
Enum value for the modal property of instances of this class indicating a non-modal dialog.

RESIZABLE

static final int RESIZABLE
Enum value for the resizable property of instances of this class indicating a resizable dialog.

RESIZEABLE

static ? RESIZEABLE
Deprecated. Renamed to RESIZABLE.
Constructor Detail

init

void init(strName : String, vntWidth : int | String, vntHeight : int | String, strTitle : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntWidthwidth in pixels
vntHeightheight in pixels
strTitleif != null, will be set as the text property on the child captionbar
Method Detail

beep

jsx3.gui.Dialog beep()
alerts the user's attention to the dialog box by making its caption bar 'flash' on-screen (as it typical with a windows modal dialog)

Returns:

this object  

constrainPosition

void constrainPosition(arg : boolean | Array<int>)
Modifies the top and left properties of this dialog in order to fit it within its parent container. This method ensures that at least a certain amount of the dialog shows on the East, South, and West edges of the server and that the entire dialog shows on the North edge.

This method is called by default after the user moves a dialog with the mouse. If an AFTER_MOVE model event is specified, then this method is not called automatically and must be called explicitly by the model event.

Parameters:

argif true, this dialog will be placed entirely within its container, with a certain amount of padding, and this dialog will be resized if necessary. If this argument is an array, it is taken as the N-E-S-W minimum pixels to show after constraining the position of the dialog. A null value for any dimension means that the entire dimension should be shown. A negative value means the number of pixels less than the size of the dialog in that dimension.

doClose

void doClose()
removes the dialog box from the JSX DOM and removes its on-screen VIEW from the browser DOM

doMaximize

void doMaximize(objTBB : jsx3.gui.ToolbarButton)
Toggles the state of the dialog between 'maximized' and its 'initial state'

Parameters:

objTBBtoolbarbutton instance on the dialog to toggle the image/tip text for

doToggleState

void doToggleState(STATE : int)
typically called by minimize/windowshade jsx3.gui.ToolbarButton in the dialog box's caption bar; toggles the window's state between full-size and window-shaded (where only the dialog's caption bar is visible); or fully minimized to the application task bar if one exists

Parameters:

STATEif != null, window state is set to fullsize (jsx3.gui.Dialog.MAXIMIZED) and window-shade (jsx3.gui.Dialog.MINIMIZED); if no value is passed, the state is toggled

focus

void focus(bTimeout : boolean)
Applies focus to the caption bar if the dialog has one; otherwise the dialog is given focus.

Parameters:

bTimeout

Overrides:


getAbsolutePosition

Object<String, int> getAbsolutePosition(objRoot : HTMLElement)
Returns the absolute positioning of the object's on-screen view (specifically, the dialog box, not its modal container if there is one) in relation to JSXROOT (whose left/top is 0/0). Returns information as a JavaScript object with properties, L, T, W, H of @objRoot is null, the on-screen view for JSXROOT is used as the object reference

Parameters:

objRootobject reference to IE DOM object (i.e., div, span, etc); if null is passed, the first div child of JSXROOT's on-screen representation will be used

Returns:

JScript object with properties: L, T, W, H (corresponding to left, top width, height)  

Overrides:


getAlertsParent

jsx3.gui.Block getAlertsParent()
Implements necessary method for the Alerts interface.

Returns:

this object.  

Overrides:


getBorder

String getBorder(strDefault : String)
Returns the outer border that surrounds the entire dialog.

Parameters:

strDefaultdefault border to use if none provided

Returns:

 

Overrides:

Since:

3.7

getBuffer

int getBuffer(strDefault : String)
Returns the uniform buffer that separates the dialog's content box, captionbar, and the outer dialog border. For example, if 2 is passed, all objects will be separated by a 2 pixel buffer

Parameters:

strDefaultdefault border to use if none provided

Returns:

 

Since:

3.7

getCaptionBar

jsx3.gui.WindowBar getCaptionBar()
Returns an object handle to the jsx3.gui.WindowBar instance associated with the jsx3.gui.Dialog instance

Returns:

jsx3.gui.WindowBar instance or null  

getContentBorder

String getContentBorder(strDefault : String)
Returns the border that surrounds the dialog content.

Parameters:

strDefaultdefault border to use if none provided

Returns:

 

Since:

3.7

getModal

int getModal()
Returns whether a dialog displays as modal or not. Modal dialogs mask the rest of the container with an semi-transparent mask that blocks mouse interaction. Modal dialogs do not show up in the task bar. Default: jsx3.gui.Dialog.NONMODAL

Returns:

one of: jsx3.gui.Dialog.NONMODAL or jsx3.gui.Dialog.MODAL  

getResize

int getResize()
Returns whether the dialog can be resized or not. Default: jsx3.gui.Dialog.RESIZABLE

Returns:

one of: jsx3.gui.Dialog.RESIZABLE jsx3.gui.Dialog.FIXED  

getTaskButton

jsx3.gui.ToolbarButton getTaskButton(objTaskBar : jsx3.gui.WindowBar)
Returns object handle to the jsx3.gui.ToolbarButton instance that resides in the application (this.getServer()) task bar and is associated with this dialog instance; returns null if none found

Parameters:

objTaskBarspecify the task bar to search in

Returns:

or null  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getWindowState

int getWindowState()
Returns state of the window (full-size / window-shaded). Default: jsx3.gui.Dialog.MAXIMIZED

Returns:

one of: jsx3.gui.Dialog.MAXIMIZED or jsx3.gui.Dialog.MINIMIZED  

getZMultiplier

int getZMultiplier()
Returns numeric multiplier for the dialog's z-index. If a dialog box needs to always be on top of other dialog box instances, this multiplier can be increased to assure the appropriate zIndex. For example, a value of 5 would mean that this dialog box would be stacked on top of all dialog boxes with a alwaysOnTop multiplier less than 5. Default: 1

Returns:

integer  

isFront

boolean isFront()
Returns whether this dialog instance is the front-most dialog among all open dialogs

Returns:

 

paint

String paint()
Returns the HTML, used for this object's on-screen VIEW

Returns:

 

Overrides:


paintChild

void paintChild(objJSX : jsx3.app.Model, bGroup : ?)
Ensures that HTML content is added to the correct VIEW element given the unique complexities of a the jsx3.gui.Dialog class

Parameters:

objJSXJSX GUI object that is already part of the dialog's MODEL, but not yet a part of its VIEW
bGroup

Overrides:


recalcBox

void recalcBox()
Removes the box model abstraction for a given object and its descendants. This effectively resets the box profiler, so dimensions can be recalculated as if the object was just broought into the visual DOM.

Overrides:


setBorder

void setBorder(strCSS : String)
Sets the outer border that surrounds the entire dialog. Only updates the model. Call repaint to update the view.

Parameters:

strCSSvalid CSS- or GI-border syntax

Overrides:

Since:

3.7

setBuffer

void setBuffer(intBuffer : int)
Sets the uniform buffer that separates the dialog's content box, captionbar, and the outer dialog border. For example, if 2 is passed, all objects will be separated by a 2 pixel buffer. Immediately updates both model and view.

Parameters:

intBuffer

Since:

3.7

setContentBorder

void setContentBorder(strCSS : String)
Sets the border that surrounds the dialog content. Only updates the model. Call repaint to update the view.

Parameters:

strCSSvalid CSS- or GI-border syntax

Since:

3.7

setModal

jsx3.gui.Dialog setModal(intModal : int)
Sets whether a dialog displays as modal or not. Modal dialogs mask the rest of the container with an semi-transparent mask that blocks mouse interaction. Modal dialogs do not show up in the task bar.

Parameters:

intModalone of: jsx3.gui.Dialog.NONMODAL or jsx3.gui.Dialog.MODAL

Returns:

this object  

setResize

jsx3.gui.Dialog setResize(RESIZE : int)
Sets whether the dialog box's on-screen view can be resized; returns reference to self to facilitate method chaining

Parameters:

RESIZEone of: jsx3.gui.Dialog.RESIZABLE jsx3.gui.Dialog.FIXED

Returns:

this object  

setResizeParameters

jsx3.gui.Dialog setResizeParameters(RESIZE : int, intMinX : int, intMinY : int, intMaxX : int, intMaxY : int, strAfterResizeFunction : ?)
Sets resize parameters such as min width, max width, etc for the dialog; returns reference to self to facilitate method chaining

Parameters:

RESIZEone of: jsx3.gui.Dialog.RESIZABLE jsx3.gui.Dialog.FIXED
intMinXmin width for the dialog when being resized
intMinYmin height for the dialog when being resized
intMaxXmax width for the dialog when being resized
intMaxYmax heightfor the dialog when being resized
strAfterResizeFunction

Returns:

this object  

setWindowState

jsx3.gui.Dialog setWindowState(STATE : int)
Sets state of the window (full-size / window-shaded); returns ref to self for method chaining

Parameters:

STATEone of: jsx3.gui.Dialog.MAXIMIZED or jsx3.gui.Dialog.MINIMIZED

Returns:

this object  

setZMultiplier

jsx3.gui.Dialog setZMultiplier(intMultiplier : int)
Sets numeric multiplier for the dialog's z-index. If a dialog box needs to always be on top of other dialog box instances, this multiplier can be increased to assure the appropriate zIndex. For example, a value of 5 would mean that this dialog box would be stacked on top of all dialog boxes with a alwaysOnTop multiplier less than 5

Parameters:

intMultiplierinteger; zero is allowed, but is not recommended; passing null is equivalent to passing 1

Returns:

this object  

jsx3.gui

class DojoWidget

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.DojoWidget

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class DojoWidget
extends jsx3.gui.Block
An adapter for Dojo widgets. Allows Dojo widgets (Dijits) to be used as GI DOM nodes from within a General Interface application.

Field Summary
dijit._Widget
The native Dojo widget object.
Constructor Summary
void
init(strName : ?, vntLeft : ?, vntTop : ?, vntWidth : ?, vntHeight : ?, dijitProps : Object)
The instance initializer.
Method Summary
void
attr(name : String, value : Object)
Gets or sets a property of the native Dojo object.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

dijit

dijit._Widget dijit
The native Dojo widget object.
Constructor Detail

init

void init(strName : ?, vntLeft : ?, vntTop : ?, vntWidth : ?, vntHeight : ?, dijitProps : Object)
The instance initializer.

Parameters:

strName
vntLeft
vntTop
vntWidth
vntHeight
dijitPropsthe properties to send to the Dojo class constructor.
Method Detail

attr

void attr(name : String, value : Object)
Gets or sets a property of the native Dojo object. Calling this method with two parameters sets the property.

Parameters:

namethe name of the property to get or set.
valuethe new value of the property.

jsx3.gui

class Event

Object
->jsx3.lang.Object
  ->jsx3.gui.Event

class Event
extends jsx3.lang.Object
Native browser event wrapper.

Since:

3.1

Field Summary
static String
The browser native event type beforeunload.
static String
The browser native event type blur.
static String
The browser native event type change.
static String
The browser native event type click.
static String
The browser native event type dblclick.
static String
The browser native event type error.
static String
The browser native event type focus.
static String
The browser native event type keydown.
static String
The browser native event type keypress.
static String
The browser native event type keyup.
static int
The browser native key code for the 0 key.
static int
The browser native key code for the 9 key.
static int
The browser native key code for the A key.
static int
The browser native key code for the Alt key.
static int
The browser native key code for the down arrow key.
static int
The browser native key code for the left arrow key.
static int
The browser native key code for the right arrow key.
static int
The browser native key code for the up arrow key.
static int
The browser native key code for the Backspace key.
static int
The browser native key code for the Ctrl key.
static int
The browser native key code for the Delete key.
static int
The browser native key code for the End key.
static int
The browser native key code for the Enter key.
static int
The browser native key code for the Esc key.
static int
The browser native key code for the F1 key.
static int
The browser native key code for the F15 key.
static int
The browser native key code for the Home key.
static int
The browser native key code for the Insert key.
static int
The browser native key code for the Meta key.
static int
The browser native key code for the number pad 0 key.
static int
The browser native key code for the number pad 9 key.
static int
The browser native key code for the number pad addition (+) key.
static int
The browser native key code for the number pad decimal (.
static int
The browser native key code for the number pad division (/) key.
static int
The browser native key code for the number pad multiply (*) key.
static int
The browser native key code for the number pad subtract (-) key.
static int
The browser native key code for the Page Down key.
static int
The browser native key code for the Page Up key.
static int
The browser native key code for the Shift key.
static int
The browser native key code for the space bar key.
static int
The browser native key code for the Tab key.
static int
The browser native key code for the Z key.
static String
The browser native event type load.
static String
The browser native event type mousedown.
static String
The browser native event type mousemove.
static String
The browser native event type mouseout.
static String
The browser native event type mouseover.
static String
The browser native event type mouseup.
static String
The browser native event type mousewheel.
static String
The browser native event type resize.
static String
The browser native event type unload.
Method Summary
boolean
Returns true if the alt key was pressed.
boolean
Returns true if the backspace key was pressed.
int
Returns integer designating the mouse button clicked/moused-down/moused-up; 1 (left), 2 (right), and as supported.
void
Cancels event bubbling for the event.
void
Cancels the key from firing by setting the keyCode to 0 (zero) for the event.
void
Cancels the return value for the event.
int
Returns the clientX property for the event (where it occurred on-screen).
int
Returns the clientY property for the event (where it occurred on-screen).
boolean
Returns true the ctrl key was pressed.
boolean
Returns true if the delete key was pressed.
boolean
Returns true if the down-arrow key was pressed.
boolean
Returns true if the end key was pressed.
boolean
Returns true if the enter key was pressed.
boolean
Returns true if the escape key was pressed.
boolean
Deprecated.
HTMLElement
Returns handle to the HTML element that was moused away from (onmouseout).
int
Returns the actual position in the browser from the left edge for where the event occurred.
int
Returns the actual position in the browser from the top edge for where the event occurred.
String
Returns the type of event, e.g.
boolean
Returns true if the home key was pressed.
boolean
Returns true if the insert key was pressed.
boolean
Whether one of the four arrow keys was pressed.
boolean
Whether one of the 15 function keys was pressed.
int
Returns integer representing the key code of the key just pressed/keyed-down.
boolean
Returns true if the left-arrow key was pressed.
boolean
Returns true if the left-mouse-button was clicked.
boolean
Returns true if the page-down key was pressed.
boolean
Returns true if the page-up key was pressed.
boolean
Returns true if the right-arrow key was pressed
boolean
Returns true if the right-mouse-button was clicked.
void
setReturn(strReturn : String)
Sets the the return value for the event.
boolean
Returns true if the shift key was pressed.
boolean
Returns true if the space bar was pressed.
HTMLElement
Returns handle to the HTML element acted upon (click, mousedown, etc).
static void
subscribe(strEventId : String, objHandler : Object | String | function, objFunction : function | String)
Subscribes an event handler to events of type strEventId that bubble all the way up to the browser window.
boolean
Returns true if the tab key was pressed.
HTMLElement
Returns handle to the HTML element that was moused over (onmouseover).
static void
unsubscribe(strEventId : String, objHandler : ?)
Unsubscribes an event handler from events of type strEventId that bubble all the way up to the browser window.
static void
unsubscribeAll(strEventId : String)
Unsubscribes all event handlers from a events of type strEventId that bubble all the way up to the browser window.
boolean
Returns true if the up-arrow key was pressed.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

BEFOREUNLOAD

static final String BEFOREUNLOAD
The browser native event type beforeunload.

BLUR

static final String BLUR
The browser native event type blur.

CHANGE

static final String CHANGE
The browser native event type change.

CLICK

static final String CLICK
The browser native event type click.

DOUBLECLICK

static final String DOUBLECLICK
The browser native event type dblclick.

ERROR

static final String ERROR
The browser native event type error.

FOCUS

static final String FOCUS
The browser native event type focus.

KEYDOWN

static final String KEYDOWN
The browser native event type keydown.

KEYPRESS

static final String KEYPRESS
The browser native event type keypress.

KEYUP

static final String KEYUP
The browser native event type keyup.

KEY_0

static final int KEY_0
The browser native key code for the 0 key.

KEY_9

static final int KEY_9
The browser native key code for the 9 key.

KEY_A

static final int KEY_A
The browser native key code for the A key.

KEY_ALT

static final int KEY_ALT
The browser native key code for the Alt key.

KEY_ARROW_DOWN

static final int KEY_ARROW_DOWN
The browser native key code for the down arrow key.

KEY_ARROW_LEFT

static final int KEY_ARROW_LEFT
The browser native key code for the left arrow key.

KEY_ARROW_RIGHT

static final int KEY_ARROW_RIGHT
The browser native key code for the right arrow key.

KEY_ARROW_UP

static final int KEY_ARROW_UP
The browser native key code for the up arrow key.

KEY_BACKSPACE

static final int KEY_BACKSPACE
The browser native key code for the Backspace key.

KEY_CONTROL

static final int KEY_CONTROL
The browser native key code for the Ctrl key.

KEY_DELETE

static final int KEY_DELETE
The browser native key code for the Delete key.

KEY_END

static final int KEY_END
The browser native key code for the End key.

KEY_ENTER

static final int KEY_ENTER
The browser native key code for the Enter key.

KEY_ESCAPE

static final int KEY_ESCAPE
The browser native key code for the Esc key.

KEY_F1

static final int KEY_F1
The browser native key code for the F1 key.

KEY_F15

static final int KEY_F15
The browser native key code for the F15 key.

KEY_HOME

static final int KEY_HOME
The browser native key code for the Home key.

KEY_INSERT

static final int KEY_INSERT
The browser native key code for the Insert key.

KEY_META

static final int KEY_META
The browser native key code for the Meta key.

KEY_NP0

static final int KEY_NP0
The browser native key code for the number pad 0 key.

KEY_NP9

static final int KEY_NP9
The browser native key code for the number pad 9 key.

KEY_NPADD

static final int KEY_NPADD
The browser native key code for the number pad addition (+) key.

KEY_NPDEC

static final int KEY_NPDEC
The browser native key code for the number pad decimal (.) key.

KEY_NPDIV

static final int KEY_NPDIV
The browser native key code for the number pad division (/) key.

KEY_NPMUL

static final int KEY_NPMUL
The browser native key code for the number pad multiply (*) key.

KEY_NPSUB

static final int KEY_NPSUB
The browser native key code for the number pad subtract (-) key.

KEY_PAGE_DOWN

static final int KEY_PAGE_DOWN
The browser native key code for the Page Down key.

KEY_PAGE_UP

static final int KEY_PAGE_UP
The browser native key code for the Page Up key.

KEY_SHIFT

static final int KEY_SHIFT
The browser native key code for the Shift key.

KEY_SPACE

static final int KEY_SPACE
The browser native key code for the space bar key.

KEY_TAB

static final int KEY_TAB
The browser native key code for the Tab key.

KEY_Z

static final int KEY_Z
The browser native key code for the Z key.

LOAD

static final String LOAD
The browser native event type load.

MOUSEDOWN

static final String MOUSEDOWN
The browser native event type mousedown.

MOUSEMOVE

static final String MOUSEMOVE
The browser native event type mousemove.

MOUSEOUT

static final String MOUSEOUT
The browser native event type mouseout.

MOUSEOVER

static final String MOUSEOVER
The browser native event type mouseover.

MOUSEUP

static final String MOUSEUP
The browser native event type mouseup.

MOUSEWHEEL

static final String MOUSEWHEEL
The browser native event type mousewheel.

RESIZE

static final String RESIZE
The browser native event type resize.

UNLOAD

static final String UNLOAD
The browser native event type unload.
Method Detail

altKey

boolean altKey()
Returns true if the alt key was pressed.

Returns:

 

backspaceKey

boolean backspaceKey()
Returns true if the backspace key was pressed.

Returns:

 

button

int button()
Returns integer designating the mouse button clicked/moused-down/moused-up; 1 (left), 2 (right), and as supported.

Returns:

 

cancelBubble

void cancelBubble()
Cancels event bubbling for the event.

cancelKey

void cancelKey()
Cancels the key from firing by setting the keyCode to 0 (zero) for the event.

cancelReturn

void cancelReturn()
Cancels the return value for the event.

clientX

int clientX()
Returns the clientX property for the event (where it occurred on-screen).

Returns:

pixel position  

clientY

int clientY()
Returns the clientY property for the event (where it occurred on-screen).

Returns:

pixel position  

ctrlKey

boolean ctrlKey()
Returns true the ctrl key was pressed.

Returns:

 

deleteKey

boolean deleteKey()
Returns true if the delete key was pressed.

Returns:

 

downArrow

boolean downArrow()
Returns true if the down-arrow key was pressed.

Returns:

 

endKey

boolean endKey()
Returns true if the end key was pressed.

Returns:

 

enterKey

boolean enterKey()
Returns true if the enter key was pressed.

Returns:

 

escapeKey

boolean escapeKey()
Returns true if the escape key was pressed.

Returns:

 

exists

boolean exists()
Deprecated.
Returns true if the native event object is present (if an event of any type actualy occurred).

Returns:

 

fromElement

HTMLElement fromElement()
Returns handle to the HTML element that was moused away from (onmouseout).

Returns:

HTML object  

getTrueX

int getTrueX()
Returns the actual position in the browser from the left edge for where the event occurred.

Returns:

pixel position  

getTrueY

int getTrueY()
Returns the actual position in the browser from the top edge for where the event occurred.

Returns:

pixel position  

getType

String getType()
Returns the type of event, e.g. mousedown, click, etc.

Returns:

event type  

homeKey

boolean homeKey()
Returns true if the home key was pressed.

Returns:

 

insertKey

boolean insertKey()
Returns true if the insert key was pressed.

Returns:

 

isArrowKey

boolean isArrowKey()
Whether one of the four arrow keys was pressed.

Returns:

 

isFunctionKey

boolean isFunctionKey()
Whether one of the 15 function keys was pressed.

Returns:

 

keyCode

int keyCode()
Returns integer representing the key code of the key just pressed/keyed-down.

Returns:

keycode  

leftArrow

boolean leftArrow()
Returns true if the left-arrow key was pressed.

Returns:

 

leftButton

boolean leftButton()
Returns true if the left-mouse-button was clicked.

Returns:

 

pageDownKey

boolean pageDownKey()
Returns true if the page-down key was pressed.

Returns:

 

pageUpKey

boolean pageUpKey()
Returns true if the page-up key was pressed.

Returns:

 

rightArrow

boolean rightArrow()
Returns true if the right-arrow key was pressed

Returns:

 

rightButton

boolean rightButton()
Returns true if the right-mouse-button was clicked.

Returns:

 

setReturn

void setReturn(strReturn : String)
Sets the the return value for the event.

Parameters:

strReturnstring message to set on the returnValue for the event

shiftKey

boolean shiftKey()
Returns true if the shift key was pressed.

Returns:

 

spaceKey

boolean spaceKey()
Returns true if the space bar was pressed.

Returns:

 

srcElement

HTMLElement srcElement()
Returns handle to the HTML element acted upon (click, mousedown, etc).

Returns:

HTML object  

subscribe

static void subscribe(strEventId : String, objHandler : Object | String | function, objFunction : function | String)
Subscribes an event handler to events of type strEventId that bubble all the way up to the browser window.

Parameters:

strEventIdthe event type, e.g. jsx3.gui.Event.CLICK.
objHandlerif an object, the instance to notify of events (objFunction is required); if a string, the JSX id of the instance to notify of events (objFunction is required), must exist in the same Server; if a function, the function to call to notify of events (objFunction ignored)
objFunctionif objHandler is a string or object then the function to call on that instance. either a function or a string that is the name of a method of the instance

See Also:


tabKey

boolean tabKey()
Returns true if the tab key was pressed.

Returns:

 

toElement

HTMLElement toElement()
Returns handle to the HTML element that was moused over (onmouseover).

Returns:

HTML object  

unsubscribe

static void unsubscribe(strEventId : String, objHandler : ?)
Unsubscribes an event handler from events of type strEventId that bubble all the way up to the browser window.

Parameters:

strEventIdthe event type, e.g. jsx3.gui.Event.CLICK.
objHandler

See Also:


unsubscribeAll

static void unsubscribeAll(strEventId : String)
Unsubscribes all event handlers from a events of type strEventId that bubble all the way up to the browser window.

Parameters:

strEventIdthe event type, e.g. jsx3.gui.Event.CLICK.

See Also:


upArrow

boolean upArrow()
Returns true if the up-arrow key was pressed.

Returns:

 

jsx3.gui

interface Form

jsx3.gui.Form

All Known Implementing Classes:

jsx3.gui.Button, jsx3.gui.CheckBox, jsx3.gui.ColorPicker, jsx3.gui.DatePicker, jsx3.gui.Grid, jsx3.gui.ImageButton, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Menu, jsx3.gui.NumberInput, jsx3.gui.RadioButton, jsx3.gui.Select, jsx3.gui.Slider, jsx3.gui.Table, jsx3.gui.TextBox, jsx3.gui.TimePicker, jsx3.gui.ToolbarButton, jsx3.gui.Tree

abstract interface Form
Mixin interface. Contains methods and constants encapsulating the functionality of an HTML form control.

Field Summary
static String
#d8d8e5 (default)
static String
#a8a8b5 (default)
static int
Value for the required field indicating that the form field is optional.
static int
Value for the required field indicating that the form field is required.
static int
Value for the enabled field indicating that the form field is disabled.
static int
Value for the enabled field indicating that the form field is enabled.
static int
Value for the validation state field indicating that the value of the form field is invalid.
static int
Value for the validation state field indicating that the value of the form field is valid.
Method Summary
jsx3.gui.HotKey
doKeyBinding(fctCallback : Function, strKeys : String)
Binds the given key sequence to a callback function.
jsx3.gui.Form
Resets the validation state of this control.
abstract int
Abstract method that must be implemented by any class that implements the Form interface.
String
Returns the background color of this control when it is disabled.
String
Returns the font color to use when this control is disabled.
int
Returns the state for the form field control.
String
Returns the key binding that when keyed will fire the execute event for this control.
int
Returns whether or not this control is required.
int
Returns the validation state of this control.
Number | String
Returns the value of this control.
static String
Deprecated.
static void
reset(objJSXContainer : jsx3.app.Model)
Traverses the DOM branch starting at objJSXContainer and calls doReset() on all nodes of type jsx3.gui.Form.
jsx3.gui.Form
Sets the background color of this form control when it is disabled.
jsx3.gui.Form
setDisabledColor(strColor : String)
Sets the font color to use when this control is disabled.
void
setEnabled(intEnabled : int, bRepaint : boolean)
Sets whether this control is enabled.
jsx3.gui.Form
setKeyBinding(strSequence : String)
Sets the key binding that when keyed will fire the bound execute (jsx3.gui.Interactive.EXECUTE) event for this control.
jsx3.gui.Form
setRequired(required : int)
Sets whether or not this control is required.
jsx3.gui.Form
setValidationState(intState : int)
Sets the validation state of this control.
jsx3.gui.Form
setValue(vntValue : Number | String)
Sets the value of this control.
static int
validate(objJSXContainer : jsx3.app.Model, objHandler : Function)
Traverses the DOM branch starting at objJSXContainer and calls doValidate() on all nodes of type jsx3.gui.Form.
Field Detail

DEFAULTDISABLEDBACKGROUNDCOLOR

static String DEFAULTDISABLEDBACKGROUNDCOLOR
#d8d8e5 (default)

DEFAULTDISABLEDCOLOR

static String DEFAULTDISABLEDCOLOR
#a8a8b5 (default)

OPTIONAL

static final int OPTIONAL
Value for the required field indicating that the form field is optional.

REQUIRED

static final int REQUIRED
Value for the required field indicating that the form field is required.

STATEDISABLED

static final int STATEDISABLED
Value for the enabled field indicating that the form field is disabled.

STATEENABLED

static final int STATEENABLED
Value for the enabled field indicating that the form field is enabled.

STATEINVALID

static final int STATEINVALID
Value for the validation state field indicating that the value of the form field is invalid.

STATEVALID

static final int STATEVALID
Value for the validation state field indicating that the value of the form field is valid.
Method Detail

doKeyBinding

jsx3.gui.HotKey doKeyBinding(fctCallback : Function, strKeys : String)
Binds the given key sequence to a callback function. Any object that has a key binding (specified with setKeyBinding()) will call this method when painted to register the key sequence with an appropriate ancestor of this form control. Any key down event that bubbles up to the ancestor without being intercepted and matches the given key sequence will invoke the given callback function.

As of 3.2: The hot key will be registered with the first ancestor found that is either a jsx3.gui.Window, a jsx3.gui.Dialog, or the root block of a jsx3.app.Server.

Parameters:

fctCallbackJavaScript function to execute when the given sequence is keyed by the user.
strKeysa plus-delimited ('+') key sequence such as ctrl+s or ctrl+shift+alt+h or shift+a, etc. Any combination of shift, ctrl, and alt are supported, including none. Also supported as the final token are enter, esc, tab, del, and space. To specify the final token as a key code, the last token can be the key code contained in brackets, [13].

Returns:

the registered hot key or null if strKeys is an invalid key combination. 

See Also:


doReset

jsx3.gui.Form doReset()
Resets the validation state of this control.

Returns:

this object.  

doValidate

abstract int doValidate()
Abstract method that must be implemented by any class that implements the Form interface.

Returns:

STATEINVALID or STATEVALID.  

getDisabledBackgroundColor

String getDisabledBackgroundColor()
Returns the background color of this control when it is disabled.

Returns:

valid CSS property value, (i.e., red, #ff0000)  

getDisabledColor

String getDisabledColor()
Returns the font color to use when this control is disabled.

Returns:

valid CSS property value, (i.e., red, #ff0000)  

getEnabled

int getEnabled()
Returns the state for the form field control. If no enabled state is set, this method returns STATEENABLED.

Returns:

STATEDISABLED or STATEENABLED

See Also:

,

getKeyBinding

String getKeyBinding()
Returns the key binding that when keyed will fire the execute event for this control.

Returns:

plus-delimited (e.g.,'+') key sequence such as ctrl+s or ctrl+shift+alt+h or shift+a, etc 

See Also:


getRequired

int getRequired()
Returns whether or not this control is required. If the required property has never been set, this method returns OPTIONAL.

Returns:

REQUIRED or OPTIONAL

See Also:

,

getValidationState

int getValidationState()
Returns the validation state of this control. If the validationState property has never been set, this method returns STATEVALID.

Returns:

STATEINVALID or STATEVALID

See Also:

,

getValue

Number | String getValue()
Returns the value of this control.

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

reset

static void reset(objJSXContainer : jsx3.app.Model)
Traverses the DOM branch starting at objJSXContainer and calls doReset() on all nodes of type jsx3.gui.Form.

Parameters:

objJSXContainerJSX GUI object containing all form fields that need to be reset (the 'reset' process will start with this item and be applied to all descendants, not just direct children)

See Also:


setDisabledBackgroundColor

jsx3.gui.Form setDisabledBackgroundColor(strColor : String)
Sets the background color of this form control when it is disabled.

Parameters:

strColorvalid CSS property value, (i.e., red, #ff0000)

Returns:

this object.  

setDisabledColor

jsx3.gui.Form setDisabledColor(strColor : String)
Sets the font color to use when this control is disabled.

Parameters:

strColorvalid CSS property value, (i.e., red, #ff0000)

Returns:

this object.  

setEnabled

void setEnabled(intEnabled : int, bRepaint : boolean)
Sets whether this control is enabled. Disabled controls do not respond to user interaction.

Parameters:

intEnabledSTATEDISABLED or STATEENABLED. null is equivalent to STATEENABLED.
bRepaintif true this control is immediately repainted to reflect the new setting.

setKeyBinding

jsx3.gui.Form setKeyBinding(strSequence : String)
Sets the key binding that when keyed will fire the bound execute (jsx3.gui.Interactive.EXECUTE) event for this control.

Parameters:

strSequenceplus-delimited (e.g.,'+') key sequence such as ctrl+s or ctrl+shift+alt+h or shift+a, etc

Returns:

this object. 

See Also:


setRequired

jsx3.gui.Form setRequired(required : int)
Sets whether or not this control is required.

Parameters:

required{int} REQUIRED or OPTIONAL.

Returns:

this object.  

setValidationState

jsx3.gui.Form setValidationState(intState : int)
Sets the validation state of this control. The validation state of a control is not serialized.

Parameters:

intStateSTATEINVALID or STATEVALID.

Returns:

this object.  

setValue

jsx3.gui.Form setValue(vntValue : Number | String)
Sets the value of this control.

Parameters:

vntValuestring/int value for the component

Returns:

this object.  

validate

static int validate(objJSXContainer : jsx3.app.Model, objHandler : Function)
Traverses the DOM branch starting at objJSXContainer and calls doValidate() on all nodes of type jsx3.gui.Form. A custom function handler, objHandler, can be passed that will be called once for each encountered form control.

Parameters:

objJSXContainerJSX GUI object containing all form fields that need to be validated (recursive validation will start with this item and be applied to all descendants, not just direct children)
objHandlera JavaScript function (as object). This function will be passed two parameters: the object reference to the JSX Form object (textbox, selectbox, checkbox, etc) being validated as well as a constant denoting whether or not it validated (0 or 1)—1 meaning true

Returns:

STATEINVALID or STATEVALID.  

jsx3.gui

class Grid

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.List
          ->jsx3.gui.Grid

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Grid
extends jsx3.gui.List
Deprecated. Use jsx3.gui.Matrix instead.
The jsx3.gui.Grid class is a subclass of the jsx3.gui.List class. It inherits all its features except that its selection model is cell-based, not row-based. Grids also support 'edit-masks' for complex real-time edits to the grid's values.

See Also:

jsx3.gui.Matrix

Field Summary
static String
background-image:url(JSX/images/list/grid.gif);
static String
#c8cfd8
static String
#c8cfd8
static String
background-image:url(JSX/images/list/header.gif);
static String
jsx30list_r2
static String
static String
url(JSX/images/grid/select.gif)
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
void
doExecute(strRecordId : String, intColumnIndex : ?)
Deprecated.
int
validates the Grid; if the Grid is set to 'required', a selection must be made to pass validation.
String
Returns name of attribute that is mapped to the cell being edited (as defined by jsxpath property for the column containing the cell).
HTMLElement
Returns a handle to the active TD for the grid.
jsx3.app.Model
Returns a handle to the active Mask for the grid.
HTMLElement
Returns a handle to the active TR for the grid.
String
Returns CSS class to use for each repeating TR in the Grid.
String
Returns jsxid attribute for the CDF record selected in the view.
boolean
Returns whether the grid will listen (true) for the tab key and advance cursor focus to the next cell in the grid
static String
Deprecated.
jsx3.xml.Document
Returns XSLT for the Grid, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default
String
Returns the DHTML, used for this object's on-screen VIEW
void
redrawRecord(strRecordId : String, ACTION : int)
reset the mask if necessary before repainting the given row
void
takes the active mask and puts at 0,0; sets visibility to hidden
jsx3.gui.Grid
setTabListener(bBOOLEAN : boolean)
ets whether the grid will listen (true) for the tab key and advance cursor focus to the next cell in the grid.
Methods Inherited From jsx3.gui.List
appendRow, clearXSL, deselectAllRecords, deselectRecord, deselectRecords, doClearSelections, doDeselect, doSelect, doSort, executeRecord, focusRecord, getAutoExpand, getBackgroundColorHead, getBackgroundHead, getCanReorder, getCanResize, getCanSort, getGrowBy, getHeaderHeight, getMultiSelect, getResizable, getResizeable, getSelectedIds, getSelectedNodes, getSortColumn, getSortDirection, getSortPath, getSortType, getValue, getWrap, isSelected, repaintBody, repaintHead, revealRecord, selectRecord, setAutoExpand, setBackgroundColorHead, setBackgroundHead, setCanReorder, setCanResize, setCanSort, setGrowBy, setHeaderHeight, setMultiSelect, setResizable, setResizeable, setSortColumn, setSortDirection, setSortPath, setSortType, setValue, setWrap, updateRow
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUND

static String DEFAULTBACKGROUND
background-image:url(JSX/images/list/grid.gif);

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#c8cfd8

DEFAULTBACKGROUNDCOLORHEAD

static String DEFAULTBACKGROUNDCOLORHEAD
#c8cfd8

DEFAULTBACKGROUNDHEAD

static String DEFAULTBACKGROUNDHEAD
background-image:url(JSX/images/list/header.gif);

DEFAULTROWCLASS

static String DEFAULTROWCLASS
jsx30list_r2

DEFAULTXSLURL

static String DEFAULTXSLURL

SELECTBGIMAGE

static String SELECTBGIMAGE
url(JSX/images/grid/select.gif)
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

doExecute

void doExecute(strRecordId : String, intColumnIndex : ?)
Deprecated.
executes any bound code for the record, @strRecordId (assuming an @strRecordId is passed); follows this execution event specific to the given record with the execution event bound to the List instance called by the system when the data rows receive a dblclick or enter key event; otherwise can be called by the developer to exectue the code specific to @strRecordId followed by the execute event for the list in general If this method is called by an 'enterkey' event or if no record id is passed, it is assumed that all elements that are selected in the list will have their execution events run

Parameters:

strRecordId'jsxid' value for the record node (according to the CDF) to execute
intColumnIndex

Overrides:


doValidate

int doValidate()
validates the Grid; if the Grid is set to 'required', a selection must be made to pass validation. Otherwise, a Grid will always pass validation

Returns:

one of: jsx3.gui.Form.STATEINVALID or jsx3.gui.Form.STATEVALID  

Overrides:


getActiveAttribute

String getActiveAttribute()
Returns name of attribute that is mapped to the cell being edited (as defined by jsxpath property for the column containing the cell).

Returns:

name of attribute or null  

getActiveCell

HTMLElement getActiveCell()
Returns a handle to the active TD for the grid.

Returns:

 

getActiveMask

jsx3.app.Model getActiveMask()
Returns a handle to the active Mask for the grid.

Returns:

 

getActiveRow

HTMLElement getActiveRow()
Returns a handle to the active TR for the grid.

Returns:

 

Overrides:


getClassName

String getClassName()
Returns CSS class to use for each repeating TR in the Grid. Default: jsx3.gui.Grid.DEFAULTROWCLASS. (Using the default class generates a fixed-height row (20px) that overlays the default background (an alternating row color defined by the jsxbg default, jsx3.gui.Grid.DEFAULTBACKGROUND).)

Returns:

valid CSS class to apply to an HTML TR element  

Overrides:


getSelectedId

String getSelectedId()
Returns jsxid attribute for the CDF record selected in the view.

Returns:

jsxid or null  

getTabListener

boolean getTabListener()
Returns whether the grid will listen (true) for the tab key and advance cursor focus to the next cell in the grid

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getXSL

jsx3.xml.Document getXSL()
Returns XSLT for the Grid, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default

Returns:

jsx3.xml.Document instance containing valid XSL stylesheet  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


redrawRecord

void redrawRecord(strRecordId : String, ACTION : int)
reset the mask if necessary before repainting the given row

Parameters:

strRecordId'jsxid' value for the record node (according to the CDF) to redraw
ACTIONOne of the following values: jsx3.xml.CDF.INSERT, jsx3.xml.CDF.DELETE, jsx3.xml.CDF.UPDATE

Overrides:


resetMask

void resetMask(objMask : jsx3.app.Model)
takes the active mask and puts at 0,0; sets visibility to hidden

Parameters:

objMaskJSX GUI object to reset; if not passed, the class will try determine the active mask and, if found, reset it

setTabListener

jsx3.gui.Grid setTabListener(bBOOLEAN : boolean)
ets whether the grid will listen (true) for the tab key and advance cursor focus to the next cell in the grid. Default: True

Parameters:

bBOOLEANone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

jsx3.gui

class Heavyweight

Object
->jsx3.lang.Object
  ->jsx3.gui.Heavyweight

class Heavyweight
extends jsx3.lang.Object
GUI utility class that provides a way to display HTML content on-screen in an HTML equivalent of a heavyweight container. Instances of this class are often used to display menu lists, select lists, spyglass, and focus-rectangles. An instance of this class cannot be serialized, it is merely a run-time construct similar to an alert or input box.

Since:

3.0

Field Summary
static int
32000
Constructor Summary
void
init(strId : String, objOwner : jsx3.gui.Painted)
instance initializer
Method Summary
static jsx3.gui.Heavyweight
GO(strId : String)
Returns the instance of the heavyweight object with the given ID; to get the on-screen HTML instance call: jsx3.gui.Heavyweight.GO([id]).getRendered()
jsx3.gui.Heavyweight
addRule(intPixel : int, strPoint : String, intOff : int, strAxis : String)
adds a POSITION RULE ruleset (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item
jsx3.gui.Heavyweight
addXRule(objAnchor : Object | jsx3.gui.Event, strAnchorPoint : String, strPoint : String, intOff : int)
adds a POSITION RULE ruleset (X value) (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item
jsx3.gui.Heavyweight
addYRule(objAnchor : Object | jsx3.gui.Event, strAnchorPoint : String, strPoint : String, intOff : int)
adds a POSITION RULE ruleset (Y value) (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item
void
applyRatio(objGUI : ?)
can be called if show() has been called; resets the ratio (width/total) of the VIEW to be that of [object].getRatio()
void
applyRules(strAxis : String, intSize : ?)
can be called if show() has been called; allows an existing HW window to re-apply its rules (used for complex layouts requiring a multi-pass)
void
destroy's the on-screen VIEW for the HW container AND removes any reference to the instance from the hash; Destroy() affects the MODEL and the VIEW
HTMLElement
Returns an object reference to the Browser Element parent to be used; if none specified, the browser BODY will be used
String
Returns the HTML content to display inside the HW instance on-screen
int
Returns the CSS height property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its height lessened to fit on-screen.
String
Returns the unique id for this heavyweight instance
String
Returns the overflow property for CONTENTS of the HW container; it is assumed that anytime a perfect fit cannot occur that the content will have its overflow property set to 'auto' unless specified otherwise
void
getPoint(objGUI : HTMLElement | jsx3.gui.Block | int, strPoint : String)
Returns a JavaScript object with properties: X,Y (Left and Top); relating to the 4 primary (N, S, E, W), 4 secondary (NE, SE, SW, NW), and origin (O) compass positions for O
String
getPositionRule(intIndex : int, strAxis : String)
Returns a POSITION RULE object at the given index; Note that POSITION RULE objects are JavaScript objects that implement the following 3 properties: _pixel (the on-screen point around which to pivot/place), _offset (amount to nudge the placement), _point (compass direction)
Object<String, Array>
Returns a JavaScript object array (hash).
Number
HTMLElement
Returns handle/reference to the Heavyweight Object's on-screen counterpart—basically a handle to a DHTML SPAN;
static String
Deprecated.
int
Returns the CSS width property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its width lessened to fit on-screen.
int
Returns the z-index property; assumes jsx3.gui.Heavyweight.DEFAULTZINDEX if none supplied
void
destorys the on-screen VIEW for the HW container; Hide() only affects the VIEW; this is not the same as setting visibility to "hidden", which doesn't actually destroy the VIEW
jsx3.gui.Heavyweight
Sets an object reference to the Browser Element parent to be used; if none specified, the browser BODY will be used.
jsx3.gui.Heavyweight
setHTML(strHTML : String, bRepaint : ?)
Sets the HTML content to display inside the HW instance on-screen; returns ref to self
jsx3.gui.Heavyweight
setHeight(intHeight : int)
Sets the CSS height property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its height lessened to fit on-screen.
jsx3.gui.Heavyweight
setOverflow(strOverflow : String)
Sets the overflow property for CONTENTS of the HW container; it is assumed that anytime a perfect fit cannot occur that the content will have its overflow property set to 'auto' unless specified otherwise returns reference to self to facilitate method chaining;
jsx3.gui.Heavyweight
setRatio(vntRatio : Number)
Sets the desired ratio of the width to the height of this heavyweight.
jsx3.gui.Heavyweight
setVisibility(strVisibility : String)
if the HW instance has an on-screen VIEW, this method can be used to toggle its visibility; it has no effect on the MODEL; it is most commonly used when "[object].show(false);" is called, allowing the developer to manually adjust layout before actually showing the HW instance.
void
setWidth(intWidth : int)
Sets the CSS width property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its width lessened to fit on-screen.
void
setZIndex(intZIndex : int)
Sets the CSS z-index for the object; if null, is passed, jsx3.gui.Heavyweight.DEFAULTZINDEX will be used as the default value
void
show(bDisplay : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;
String
converts the object to a string representation more useful than the default implementation provided by the native JS engine
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTZINDEX

static int DEFAULTZINDEX
32000
Constructor Detail

init

void init(strId : String, objOwner : jsx3.gui.Painted)
instance initializer

Parameters:

strIdid to identify this HW instance among all others; this id will be used by both jsx3.gui.Heavyweight (to index it in the hash) and by the browser as the HTML tag's "id" attribute. If no ID is passed, a unique ID will be assigned by the system and is available by calling, [object].getId();
objOwner
Method Detail

GO

static jsx3.gui.Heavyweight GO(strId : String)
Returns the instance of the heavyweight object with the given ID; to get the on-screen HTML instance call: jsx3.gui.Heavyweight.GO([id]).getRendered()

Parameters:

strIdunique ID for the heavyweight instance

Returns:

 

addRule

jsx3.gui.Heavyweight addRule(intPixel : int, strPoint : String, intOff : int, strAxis : String)
adds a POSITION RULE ruleset (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item

Parameters:

intPixelleft position (in pixels) for the anchorpoint the heavyweight instance will try to layout in context of
strPointDefines one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O). Note that it is from this point (on the Heavyweight instance) that the heavyweight item will try to position itself
intOffoffset (in pixels) by which to nudge the vertical placement of the HW instance before displaying (useful for submenus, for example, where their left has a -10px offset to overlay the parent menu item)
strAxischaracter (string) representing whether the rule is for the X or Y axis. Rememeber to capitalize!

Returns:

this object (this)  

addXRule

jsx3.gui.Heavyweight addXRule(objAnchor : Object | jsx3.gui.Event, strAnchorPoint : String, strPoint : String, intOff : int)
adds a POSITION RULE ruleset (X value) (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item

Parameters:

objAnchorEither an event, or an on-screen HTML element
strAnchorPointREQUIRED if @objAnchor is an HTML element; when used, defines one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O). Note that it is from this point (on @objAnchor) that the heavyweight item will try to position itself
strPointDefines one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O). Note that it is from this point (on the Heavyweight instance) that the heavyweight item will try to position itself
intOffoffset (in pixels) by which to nudge the horizontal placement of the HW instance before displaying (useful for submenus, for example, where their left has a -10px offset to overlay the parent menu item)

Returns:

this object (this)  

addYRule

jsx3.gui.Heavyweight addYRule(objAnchor : Object | jsx3.gui.Event, strAnchorPoint : String, strPoint : String, intOff : int)
adds a POSITION RULE ruleset (Y value) (a simple structure/hash) to the array of position rules; Note that POSITION RULE objects are used by the show() method to determine the best possible location for a heavyweight item

Parameters:

objAnchorEither an event or an on-screen HTML element
strAnchorPointREQUIRED if @objAnchor is an HTML element; when used, defines one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O). Note that it is from this point (on @objAnchor) that the heavyweight item will try to position itself
strPointDefines one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O). Note that it is from this point (on the Heavyweight instance) that the heavyweight item will try to position itself
intOffoffset (in pixels) by which to nudge the vertical placement of the HW instance before displaying (useful for submenus, for example, where their left has a -10px offset to overlay the parent menu item)

Returns:

this object (this)  

applyRatio

void applyRatio(objGUI : ?)
can be called if show() has been called; resets the ratio (width/total) of the VIEW to be that of [object].getRatio()

Parameters:

objGUI

applyRules

void applyRules(strAxis : String, intSize : ?)
can be called if show() has been called; allows an existing HW window to re-apply its rules (used for complex layouts requiring a multi-pass)

Parameters:

strAxischaracter (string) representing whether the rule is for the X or Y axis. Rememeber to capitalize!
intSize

destroy

void destroy()
destroy's the on-screen VIEW for the HW container AND removes any reference to the instance from the hash; Destroy() affects the MODEL and the VIEW

getDomParent

HTMLElement getDomParent()
Returns an object reference to the Browser Element parent to be used; if none specified, the browser BODY will be used

Returns:

 

getHTML

String getHTML()
Returns the HTML content to display inside the HW instance on-screen

Returns:

 

getHeight

int getHeight()
Returns the CSS height property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its height lessened to fit on-screen.

Returns:

height (in pixels)  

getId

String getId()
Returns the unique id for this heavyweight instance

Returns:

 

getOverflow

String getOverflow()
Returns the overflow property for CONTENTS of the HW container; it is assumed that anytime a perfect fit cannot occur that the content will have its overflow property set to 'auto' unless specified otherwise

Returns:

[jsx3.gui.Block.OVERFLOWSCROLL, jsx3.gui.Block.OVERFLOWHIDDEN, jsx3.gui.Block.OVERFLOWEXPAND]  

getPoint

void getPoint(objGUI : HTMLElement | jsx3.gui.Block | int, strPoint : String)
Returns a JavaScript object with properties: X,Y (Left and Top); relating to the 4 primary (N, S, E, W), 4 secondary (NE, SE, SW, NW), and origin (O) compass positions for O

Parameters:

objGUIGUI object in the browser DOM (typically an HTML element such as a DIV or SPAN) for which to provide the X,Y for
strPointa character denoting one of the valid 9 compass points: 4 primary: (N, S, E, W); 4 secondary: (NE, SE, SW, NW); and origin: (O)

getPositionRule

String getPositionRule(intIndex : int, strAxis : String)
Returns a POSITION RULE object at the given index; Note that POSITION RULE objects are JavaScript objects that implement the following 3 properties: _pixel (the on-screen point around which to pivot/place), _offset (amount to nudge the placement), _point (compass direction)

Parameters:

intIndexthe index (in rank order of execution) of the POSITION RULEing rule set to apply (it is assumed that at least one POSITION RULE ruleset exists)
strAxischaracter (string) representing whether the rule is for the X or Y axis. Rememeber to capitalize!

Returns:

 

getPositionRules

Object<String, Array> getPositionRules()
Returns a JavaScript object array (hash). This hash contains the Y rules and the X rules for positioning the object

Returns:

 

getRatio

Number getRatio()

Returns:

 

getRendered

HTMLElement getRendered(objGUI : jsx3.gui.Event | HTMLElement | HTMLDocument)
Returns handle/reference to the Heavyweight Object's on-screen counterpart—basically a handle to a DHTML SPAN;

Parameters:

objGUIoptional argument improves efficiency if provided.

Returns:

Browser-Native DHTML object  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getWidth

int getWidth()
Returns the CSS width property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its width lessened to fit on-screen.

Returns:

width (in pixels)  

getZIndex

int getZIndex()
Returns the z-index property; assumes jsx3.gui.Heavyweight.DEFAULTZINDEX if none supplied

Returns:

 

hide

void hide()
destorys the on-screen VIEW for the HW container; Hide() only affects the VIEW; this is not the same as setting visibility to "hidden", which doesn't actually destroy the VIEW

setDomParent

jsx3.gui.Heavyweight setDomParent(objGUI : HTMLElement)
Sets an object reference to the Browser Element parent to be used; if none specified, the browser BODY will be used. Note that this method must be called before setting any point rules for the hW instance, so those functions know the true origin from which to calculate left/top positions; returns ref to self

Parameters:

objGUIHTML element in the browser

Returns:

this  

setHTML

jsx3.gui.Heavyweight setHTML(strHTML : String, bRepaint : ?)
Sets the HTML content to display inside the HW instance on-screen; returns ref to self

Parameters:

strHTMLHTML
bRepaint

Returns:

this  

setHeight

jsx3.gui.Heavyweight setHeight(intHeight : int)
Sets the CSS height property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its height lessened to fit on-screen. returns reference to self to facilitate method chaining;

Parameters:

intHeightheight (in pixels)

Returns:

this object  

setOverflow

jsx3.gui.Heavyweight setOverflow(strOverflow : String)
Sets the overflow property for CONTENTS of the HW container; it is assumed that anytime a perfect fit cannot occur that the content will have its overflow property set to 'auto' unless specified otherwise returns reference to self to facilitate method chaining;

Parameters:

strOverflow[jsx3.gui.Block.OVERFLOWSCROLL, jsx3.gui.Block.OVERFLOWHIDDEN, jsx3.gui.Block.OVERFLOWEXPAND]

Returns:

this object  

setRatio

jsx3.gui.Heavyweight setRatio(vntRatio : Number)
Sets the desired ratio of the width to the height of this heavyweight. This class will attempt to resize the content to fit inside a box with this width to height ratio.

Parameters:

vntRatio

Returns:

this object.  

setVisibility

jsx3.gui.Heavyweight setVisibility(strVisibility : String)
if the HW instance has an on-screen VIEW, this method can be used to toggle its visibility; it has no effect on the MODEL; it is most commonly used when "[object].show(false);" is called, allowing the developer to manually adjust layout before actually showing the HW instance. returns a ref to self for method chaining

Parameters:

strVisibility[jsx3.gui.Block.VISIBILITYVISIBLE, jsx3.gui.Block.VISIBILITYHIDDEN]

Returns:

this object  

setWidth

void setWidth(intWidth : int)
Sets the CSS width property (in pixels); if this value is set, it is assumed that the Heavyweight container will not have its width lessened to fit on-screen.

Parameters:

intWidthwidth (in pixels)

setZIndex

void setZIndex(intZIndex : int)
Sets the CSS z-index for the object; if null, is passed, jsx3.gui.Heavyweight.DEFAULTZINDEX will be used as the default value

Parameters:

intZIndexz-index value

show

void show(bDisplay : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;

Parameters:

bDisplaytrue if null; if true, the heavyweight container is positioned and displayed immediately; if false, the container is painted on-screen, but its CSS 'visibility' property is set to 'hidden', allowing the developer to adjust as needed (via 2-pass, etc) before actually displaying;

toString

String toString()
converts the object to a string representation more useful than the default implementation provided by the native JS engine

Returns:

object profile as a string  

Overrides:


jsx3.gui

class HotKey

Object
->jsx3.lang.Object
  ->jsx3.gui.HotKey

All Implemented Interfaces:

jsx3.util.EventDispatcher

class HotKey
extends jsx3.lang.Object
Encapsulates a keydown event listener that is invoked by a certain combination of keys pressed simultaneously.

Since:

3.2

See Also:

,

Field Summary
static String
Event type published just after a hot key is invoked.
Method Summary
void
Destroys this hot key.
int
Returns the keycode that this hot key responds to.
Object
invoke(objThis : Object, arrArgs : Array<Object>)
Invokes this hot key by executing its callback function.
boolean
Returns whether this hot key had been destoyed.
boolean
Returns whether this hot key is enabled.
boolean
isMatch(objEvent : jsx3.gui.Event)
Returns whether this hot key should be invoked for the keydown event objEvent.
static int
Converts the string representation of a keyboard key to an integer keycode.
void
setEnabled(bEnabled : boolean)
Sets whether this hot key is enabled.
String
static jsx3.gui.HotKey
valueOf(strKey : String, fctCallback : Function)
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

WAS_INVOKED

static final String WAS_INVOKED
Event type published just after a hot key is invoked.
Method Detail

destroy

void destroy()
Destroys this hot key. Once a hot key is destroyed it cannot be invoked again.

getKeyCode

int getKeyCode()
Returns the keycode that this hot key responds to.

Returns:

 

invoke

Object invoke(objThis : Object, arrArgs : Array<Object>)
Invokes this hot key by executing its callback function. This hot key also publishes a WAS_INVOKED event through the event dispatcher interface.

Parameters:

objThis
arrArgs

Returns:

this method returns whatever value was returned by the hot key callback function.  

isDestroyed

boolean isDestroyed()
Returns whether this hot key had been destoyed.

Returns:

 

isEnabled

boolean isEnabled()
Returns whether this hot key is enabled.

Returns:

 

isMatch

boolean isMatch(objEvent : jsx3.gui.Event)
Returns whether this hot key should be invoked for the keydown event objEvent.

Parameters:

objEvent

Returns:

 

keyDownCharToCode

static int keyDownCharToCode(strChar : String)
Converts the string representation of a keyboard key to an integer keycode. This keycode will match the keycode value of a jsx3.gui.Event of type keydown.

The following string representations are supported:
  • alpha numeric characters: A-Z, a-z, 0-9
  • the punctuation keys in the string: ";,./'[]\-=`"
  • functions keys: F1-F15
  • special keys: enter, esc, tab, del, space, backspace, up, down, left, right, insert, home, end, pgup, pgdn.

Parameters:

strCharthe string representation of a key.

Returns:

the keycode.  

setEnabled

void setEnabled(bEnabled : boolean)
Sets whether this hot key is enabled. Hot keys may be turned off temporarily by sending false to this method.

Parameters:

bEnabled

toString

String toString()

Returns:

 

Overrides:


valueOf

static jsx3.gui.HotKey valueOf(strKey : String, fctCallback : Function)

Parameters:

strKey
fctCallback

Returns:

 

jsx3.gui

class IFrame

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.IFrame

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class IFrame
extends jsx3.gui.Block
Renders an IFrame.

Since:

3.4

Field Summary
static int
static int
static int
Method Summary
HTMLDocument
Returns the native document object of this iframe.
HTMLElement
Returns the native iframe object of this iframe.
int
Returns the scroll mode of this iframe.
String
Returns the URI of this iframe.
String
Serializes this object to HTML.
jsx3.gui.IFrame
setScrolling(intScrolling : int)
Sets the scroll mode of this iframe.
jsx3.gui.IFrame
setSrc(srcSrc : String)
Sets the URI of this iframe.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

SCROLLAUTO

static final int SCROLLAUTO

SCROLLNO

static final int SCROLLNO

SCROLLYES

static final int SCROLLYES
Method Detail

getContentDocument

HTMLDocument getContentDocument()
Returns the native document object of this iframe. Depending on browser security settings and the URL of this iframe, the native document object may not be available. In this case, this method returns null.

Returns:

 

getIFrame

HTMLElement getIFrame()
Returns the native iframe object of this iframe. Depending on browser security settings and the URL of this iframe, the native iframe object may not be available. In this case, this method returns null.

Returns:

 

getScrolling

int getScrolling()
Returns the scroll mode of this iframe.

Returns:

 

getSrc

String getSrc()
Returns the URI of this iframe.

Returns:

 

paint

String paint()
Serializes this object to HTML.

Returns:

 

Overrides:


setScrolling

jsx3.gui.IFrame setScrolling(intScrolling : int)
Sets the scroll mode of this iframe.

Parameters:

intScrollingone of SCROLLYES, SCROLLNO, or SCROLLAUTO.

Returns:

this object.  

setSrc

jsx3.gui.IFrame setSrc(srcSrc : String)
Sets the URI of this iframe. The URI can be absolute or relative from the content base of the server that owns this object. If this iframe is rendered on screen, its location is updated immediately.

Parameters:

srcSrc

Returns:

this object.  

jsx3.gui

class Image

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Image

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Image
extends jsx3.gui.Block
Renders an image.

Since:

3.2

Method Summary
int
int
String
Returns the URI of this image.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Image
setSrc(srcSrc : String)
Sets the URI of this image.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

getRenderedHeight

int getRenderedHeight()

Returns:

 

getRenderedWidth

int getRenderedWidth()

Returns:

 

getSrc

String getSrc()
Returns the URI of this image.

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setSrc

jsx3.gui.Image setSrc(srcSrc : String)
Sets the URI of this image. The URI can be absolute or relative from the content base of the server that owns this object.

Parameters:

srcSrc

Returns:

this object  

jsx3.gui

class ImageButton

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.ImageButton

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class ImageButton
extends jsx3.gui.Block
An object-oriented interface onto a GUI button made of various image files. The class allows for an image file for the following states: The following model events are published:

Since:

3.1

Field Summary
static int
Value for the state field indicating that the toggle button is off.
static int
Value for the state field indicating that the toggle button is on.
static int
Value for the type field indicating a normal button.
static int
Value for the type field indicating a toggle (2-state) button.
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int, vntHeight : int)
The instance initializer.
Method Summary
int
If this image button is of type TYPE_TOGGLE, then the state must be either STATE_ON or required must be OPTIONAL to pass validation.
String
Returns the URI of the disabled image of this image button.
String
Returns the URI of the down image of this image button.
String
Returns the URI of the image of this image button.
String
Returns the URI of the on image of this image button.
String
Returns the URI of the over image of this image button.
int
Returns the current state of this image button.
int
Returns the type of this image button.
boolean
Returns true if the images of this image button are pre-fetched.
String
Paints this image button.
jsx3.gui.ImageButton
setDisabledImage(strImage : String)
Sets the URI of the disabled image of this image button.
jsx3.gui.ImageButton
setDownImage(strImage : String)
Sets the URI of the down image of this image button.
jsx3.gui.ImageButton
setImage(strImage : String)
Sets the URI of the image of this image button.
jsx3.gui.ImageButton
setOnImage(strImage : String)
Sets the URI of the on image of this image button.
jsx3.gui.ImageButton
setOverImage(strImage : String)
Sets the URI of the over image of this image button.
jsx3.gui.ImageButton
setPreFetch(bFetch : boolean)
Sets whether if the images of this image button are pre-fetched.
jsx3.gui.ImageButton
setState(intState : int)
Sets the current state of this image button and updates the displayed image accordingly.
jsx3.gui.ImageButton
setType(intType : int)
Sets the type of this image button.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, getValue, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState, setValue
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

STATE_OFF

static final int STATE_OFF
Value for the state field indicating that the toggle button is off.

STATE_ON

static final int STATE_ON
Value for the state field indicating that the toggle button is on.

TYPE_NORMAL

static final int TYPE_NORMAL
Value for the type field indicating a normal button.

TYPE_TOGGLE

static final int TYPE_TOGGLE
Value for the type field indicating a toggle (2-state) button.
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int, vntHeight : int)
The instance initializer.

Parameters:

strNamethe JSX name
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidth
vntHeight
Method Detail

doValidate

int doValidate()
If this image button is of type TYPE_TOGGLE, then the state must be either STATE_ON or required must be OPTIONAL to pass validation.

Returns:

 

Overrides:


getDisabledImage

String getDisabledImage()
Returns the URI of the disabled image of this image button.

Returns:

 

getDownImage

String getDownImage()
Returns the URI of the down image of this image button.

Returns:

 

getImage

String getImage()
Returns the URI of the image of this image button.

Returns:

 

getOnImage

String getOnImage()
Returns the URI of the on image of this image button.

Returns:

 

getOverImage

String getOverImage()
Returns the URI of the over image of this image button.

Returns:

 

getState

int getState()
Returns the current state of this image button.

Returns:

STATE_OFF or STATE_ON 

See Also:

,

getType

int getType()
Returns the type of this image button.

Returns:

TYPE_NORMAL or TYPE_TOGGLE 

See Also:

,

isPreFetch

boolean isPreFetch()
Returns true if the images of this image button are pre-fetched.

Returns:

 

paint

String paint()
Paints this image button.

Returns:

 

Overrides:


setDisabledImage

jsx3.gui.ImageButton setDisabledImage(strImage : String)
Sets the URI of the disabled image of this image button. This is the image that is displayed when this image button disabled.

Parameters:

strImage

Returns:

this object  

setDownImage

jsx3.gui.ImageButton setDownImage(strImage : String)
Sets the URI of the down image of this image button. This is the image that is displayed when the mouse is down over the image button.

Parameters:

strImage

Returns:

this object  

setImage

jsx3.gui.ImageButton setImage(strImage : String)
Sets the URI of the image of this image button. This is the default image that is displayed if the button is off or if the button is in a state for which no image URI is specified.

Parameters:

strImage

Returns:

this object  

setOnImage

jsx3.gui.ImageButton setOnImage(strImage : String)
Sets the URI of the on image of this image button. This is the image that is displayed when this image button is of type TYPE_TOGGLE and its state is STATE_ON.

Parameters:

strImage

Returns:

this object  

setOverImage

jsx3.gui.ImageButton setOverImage(strImage : String)
Sets the URI of the over image of this image button. This is the image that is displayed when the mouse moves over the image button.

Parameters:

strImage

Returns:

this object  

setPreFetch

jsx3.gui.ImageButton setPreFetch(bFetch : boolean)
Sets whether if the images of this image button are pre-fetched. Pre-fetching allows for better responsiveness the first time a state image is displayed.

Parameters:

bFetch

Returns:

this object  

setState

jsx3.gui.ImageButton setState(intState : int)
Sets the current state of this image button and updates the displayed image accordingly.

Parameters:

intStateSTATE_OFF or STATE_ON

Returns:

this object  

setType

jsx3.gui.ImageButton setType(intType : int)
Sets the type of this image button.

Parameters:

intTypeTYPE_NORMAL or TYPE_TOGGLE

Returns:

this object  

jsx3.gui

interface Interactive

jsx3.gui.Interactive

All Known Implementing Classes:

jsx3.chart.AreaChart, jsx3.chart.AreaSeries, jsx3.chart.Axis, jsx3.chart.BCChart, jsx3.chart.BCSeries, jsx3.chart.BarChart, jsx3.chart.BarSeries, jsx3.chart.BubbleSeries, jsx3.chart.CartesianChart, jsx3.chart.CategoryAxis, jsx3.chart.Chart, jsx3.chart.ChartComponent, jsx3.chart.ChartLabel, jsx3.chart.ColumnChart, jsx3.chart.ColumnSeries, jsx3.chart.GridLines, jsx3.chart.Legend, jsx3.chart.LineChart, jsx3.chart.LineSeries, jsx3.chart.LinearAxis, jsx3.chart.LogarithmicAxis, jsx3.chart.PieChart, jsx3.chart.PieSeries, jsx3.chart.PlotChart, jsx3.chart.PlotSeries, jsx3.chart.PointSeries, jsx3.chart.RadialChart, jsx3.chart.Series, jsx3.gui.Block, jsx3.gui.BlockX, jsx3.gui.Button, jsx3.gui.CDF, jsx3.gui.CheckBox, jsx3.gui.ColorPicker, jsx3.gui.Column, jsx3.gui.DatePicker, jsx3.gui.Dialog, jsx3.gui.DojoWidget, jsx3.gui.Grid, jsx3.gui.IFrame, jsx3.gui.Image, jsx3.gui.ImageButton, jsx3.gui.LayoutGrid, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Matrix.Column, jsx3.gui.Menu, jsx3.gui.NumberInput, jsx3.gui.RadioButton, jsx3.gui.Select, jsx3.gui.Slider, jsx3.gui.Sound, jsx3.gui.Splitter, jsx3.gui.Stack, jsx3.gui.StackGroup, jsx3.gui.Tab, jsx3.gui.TabbedPane, jsx3.gui.Table, jsx3.gui.Template.Block, jsx3.gui.TextBox, jsx3.gui.TimePicker, jsx3.gui.ToolbarButton, jsx3.gui.Tree, jsx3.gui.WindowBar, jsx3.vector.Block

interface Interactive
Mixin interface. Provides functionality to subclasses of jsx3.gui.Painted that allows them to publish model events.

Note that this class requires that implementors of this class extends the jsx3.gui.Painted class and implement the jsx3.util.EventDispatcher interface

Field Summary
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
static String
Method Summary
Object
doEvent(strType : String, objContext : Object<String, Object>)
Publishes a model event.
int
Returns whether is object supports programmatic drag, meanining it will allow any contained item to be dragged and dropped on another container supporting drop.
int
Returns whether this object can be the target of a drop event.
int
Returns whether is object can be moved around the screen (this is not the same as drag/drop).
int
Returns whether is object can be spyglassed.
String
getEvent(strType : String)
Returns the event script registered for the given event type.
Object<String, String>
Returns the associative array containing all the registered event script of this object.
String
Returns the name of the jsx3.gui.Menu instance to display (as a context menu) when a user clicks on this object with the right button.
static String
Deprecated.
String
hasEvent(strType : String)
Returns true if there is a event script registered for the given event type.
jsx3.gui.HotKey
registerHotKey(vntCallback : String | Function | jsx3.gui.HotKey, vntKey : int | String, bShift : boolean, bControl : boolean, bAlt : boolean)
Registers a hot key with this JSX model node.
jsx3.gui.Interactive
removeEvent(strType : String)
Removes an event script registered for the given model event type.
jsx3.gui.Interactive
Removes all events scripts registered with this object.
jsx3.gui.Interactive
setCanDrag(bDrag : int)
Sets whether is object supports programmatic drag, meanining it will allow any contained item to be dragged/dropped.
jsx3.gui.Interactive
setCanDrop(bDrop : int)
Sets whether this object can be the target of a drop event.
jsx3.gui.Interactive
setCanMove(bMovable : int)
Sets whether is object can be moved around the screen (this is not the same as drag/drop).
jsx3.gui.Interactive
setCanSpy(bSpy : int)
Sets whether is object can be spyglassed.
jsx3.gui.Interactive
setEvent(strScript : String, strType : String)
Programmatically sets an event of this instance.
jsx3.gui.Interactive
setMenu(strMenu : String)
Sets the name of the jsx3.gui.Menu instance to display when a user clicks on this object with the right button.
void
setSpyStyles(strCSS : String)
Sets the CSS definition to apply to an HTML element when a spyglass is shown for that element
void
showSpy(strHTML : String, intLeft : int | jsx3.gui.Event, intTop : int)
called by 'window.setTimeout()' to display the spyglass hover for a given object;
Field Detail

ADOPT

static final String ADOPT

AFTER_APPEND

static final String AFTER_APPEND

AFTER_COMMIT

static final String AFTER_COMMIT

AFTER_EDIT

static final String AFTER_EDIT

AFTER_MOVE

static final String AFTER_MOVE

AFTER_REORDER

static final String AFTER_REORDER

AFTER_RESIZE

static final String AFTER_RESIZE

AFTER_RESIZE_VIEW

static final String AFTER_RESIZE_VIEW

AFTER_SORT

static final String AFTER_SORT

BEFORE_APPEND

static final String BEFORE_APPEND

BEFORE_DROP

static final String BEFORE_DROP

BEFORE_EDIT

static final String BEFORE_EDIT

BEFORE_MOVE

static final String BEFORE_MOVE

BEFORE_RESIZE

static final String BEFORE_RESIZE

BEFORE_SELECT

static final String BEFORE_SELECT

BEFORE_SORT

static final String BEFORE_SORT

CANCEL_DROP

static final String CANCEL_DROP

CHANGE

static final String CHANGE

CTRL_DROP

static final String CTRL_DROP

DATA

static final String DATA

DESTROY

static final String DESTROY

DRAG

static final String DRAG

DROP

static final String DROP

EXECUTE

static final String EXECUTE

FOCUS_STYLE

static final String FOCUS_STYLE

HIDE

static final String HIDE

INCR_CHANGE

static final String INCR_CHANGE

INPUT

static final String INPUT

JSXBLUR

static final String JSXBLUR

JSXCHANGE

static final String JSXCHANGE

JSXCLICK

static final String JSXCLICK

JSXDOUBLECLICK

static final String JSXDOUBLECLICK

JSXFOCUS

static final String JSXFOCUS

JSXKEYDOWN

static final String JSXKEYDOWN

JSXKEYPRESS

static final String JSXKEYPRESS

JSXKEYUP

static final String JSXKEYUP

JSXLOAD

static final String JSXLOAD

JSXMOUSEDOWN

static final String JSXMOUSEDOWN

JSXMOUSEOUT

static final String JSXMOUSEOUT

JSXMOUSEOVER

static final String JSXMOUSEOVER

JSXMOUSEUP

static final String JSXMOUSEUP

JSXMOUSEWHEEL

static final String JSXMOUSEWHEEL

MENU

static final String MENU

SCROLL

static final String SCROLL

SELECT

static final String SELECT

SHOW

static final String SHOW

SPYGLASS

static final String SPYGLASS

TOGGLE

static final String TOGGLE
Method Detail

doEvent

Object doEvent(strType : String, objContext : Object<String, Object>)
Publishes a model event. This method both evaluates any registered event script for the given event type and publishes the event through the EventDispatcher interface. This method ensures that any registered event script is executed in isolation to prevent most side effects.

Parameters:

strTypethe event type, one of the model event types defined as static fields in this class
objContextJavaScript object array with name/value pairs that provide a local variable stack for the execution of the event script. This argument is also passed as the context property of the event object that is published through the EventDispatcher interface.

Returns:

the result of evaluating the event script or null if not event script is registered  

getCanDrag

int getCanDrag()
Returns whether is object supports programmatic drag, meanining it will allow any contained item to be dragged and dropped on another container supporting drop.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getCanDrop

int getCanDrop()
Returns whether this object can be the target of a drop event.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getCanMove

int getCanMove()
Returns whether is object can be moved around the screen (this is not the same as drag/drop).

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getCanSpy

int getCanSpy()
Returns whether is object can be spyglassed.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getEvent

String getEvent(strType : String)
Returns the event script registered for the given event type. This script could have been set by the setEvent() method or during component deserialization.

Parameters:

strTypethe event type, one of the model event types defined as static fields in this class

Returns:

the JavaScript event script 

See Also:


getEvents

Object<String, String> getEvents()
Returns the associative array containing all the registered event script of this object. This method returns the instance field itself and not a copy.

Returns:

an associative array mapping event type to event script  

getMenu

String getMenu()
Returns the name of the jsx3.gui.Menu instance to display (as a context menu) when a user clicks on this object with the right button.

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

hasEvent

String hasEvent(strType : String)
Returns true if there is a event script registered for the given event type.

Parameters:

strTypethe event type, one of the model event types defined as static fields in this class

Returns:

the JavaScript event script  

registerHotKey

jsx3.gui.HotKey registerHotKey(vntCallback : String | Function | jsx3.gui.HotKey, vntKey : int | String, bShift : boolean, bControl : boolean, bAlt : boolean)
Registers a hot key with this JSX model node. All keydown events that bubble up to this object will be checked against the hot key. If an event matches, the callback function will execute and the event bubble will be canceled.

If the four parameters vntKey, bShift, bControl, and bAlt match a previously registered hot key, the previous hot key is clobbered by the new one. Only one hot key callback function (the most recently registered) will be executed by a single keydown event.

Parameters:

vntCallbackeither a function, or the name of a method bound to this object. When a keydown event bubbles up to this object that matches the hot key created by this method, this function is called on this object. If this function returns false then this hot key will not cancel the key event. This parameter can also be an instance of HotKey, in which case all other parameters are ignored.
vntKeyif this parameter is a String, the hot key matches that key (the keycode to match is determined by HotKey.keyDownCharToCode()). If it is an integer, the hot key will match that keycode value.
bShiftif not null the shift key state of the keydown event must match this value to invoke the hot key.
bControlif not null the control key state of the keydown event must match this value to invoke the hot key.
bAltif not null the alt key state of the keydown event must match this value to invoke the hot key.

Returns:

the registered hot key. 

See Also:


removeEvent

jsx3.gui.Interactive removeEvent(strType : String)
Removes an event script registered for the given model event type.

Parameters:

strTypethe event type, one of the model event types defined as static fields in this class

Returns:

this object  

removeEvents

jsx3.gui.Interactive removeEvents()
Removes all events scripts registered with this object.

Returns:

this object  

setCanDrag

jsx3.gui.Interactive setCanDrag(bDrag : int)
Sets whether is object supports programmatic drag, meanining it will allow any contained item to be dragged/dropped. Implementing classes can decide whether to consult this value or ignore it.

Parameters:

bDragjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setCanDrop

jsx3.gui.Interactive setCanDrop(bDrop : int)
Sets whether this object can be the target of a drop event. Implementing classes can decide whether to consult this value or ignore it.

Parameters:

bDropjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setCanMove

jsx3.gui.Interactive setCanMove(bMovable : int)
Sets whether is object can be moved around the screen (this is not the same as drag/drop). Implementing classes can decide whether to consult this value or ignore it.

Parameters:

bMovablejsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setCanSpy

jsx3.gui.Interactive setCanSpy(bSpy : int)
Sets whether is object can be spyglassed. Implementing classes can decide whether to consult this value or ignore it.

Parameters:

bSpyjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setEvent

jsx3.gui.Interactive setEvent(strScript : String, strType : String)
Programmatically sets an event of this instance. Sets the script that will execute when this object publishes a model event. The script value will be saved in the serialization file of a component. Not all classes that implement this interface will publish events of every type. Consult the documentation of a class for a description of the events it publishes.

For programmatic registering of event handlers when persistence in a serialization file is not required, consider using jsx3.util.EventDispatcher.subscribe() instead of this method. Whenever a model event is published, it is published using the EventDispatcher interface as well as by executing any registered event script.

Parameters:

strScriptthe actual JavaScript code that will execute when the given event is published. For example: obj.setEvent("alert('hello.');", jsx3.gui.Interactive.EXECUTE);
strTypethe event type. Must be one of the model event types defined as static fields in this class

Returns:

reference to this 

See Also:


setMenu

jsx3.gui.Interactive setMenu(strMenu : String)
Sets the name of the jsx3.gui.Menu instance to display when a user clicks on this object with the right button. The name is a pointer by-name to a JSX object in the same server.

Parameters:

strMenuname or id (jsxname or jsxid) of the context menu

Returns:

this object  

setSpyStyles

void setSpyStyles(strCSS : String)
Sets the CSS definition to apply to an HTML element when a spyglass is shown for that element

Parameters:

strCSSvalid CSS. For example, text-decoration:underline;color:red;

showSpy

void showSpy(strHTML : String, intLeft : int | jsx3.gui.Event, intTop : int)
called by 'window.setTimeout()' to display the spyglass hover for a given object;

Parameters:

strHTMLHTML/text to display in the spyglass; as the spyglass does not define a height/width, this content will have improved layout if it specifies a preferred width in its in-line-style or referenced-css rule.
intLeftuse an integer to specify an on-screen location; otherwise, use a jsx3.gui.Event instance to have the system automatically calculate the x/y position.
intTopuse an integer if intLeft also uses an integer. Otherwise, use null.

jsx3.gui

class LayoutGrid

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.LayoutGrid

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.gui.StackGroup

class LayoutGrid
extends jsx3.gui.Block
This class provides a way to organize a set of GUI objects in a grid. The dimensions of each cell in the grid are determined by the row heights and column widths. The height of each row and width of each column may be defined either as a percent, an integer pixel value, or as "*". Each dimension may specify one or more divisions as "*", in which case these rows/columns share the remaining space in that dimension equally once the other rows/columns are fitted.

GUI objects that are children of this DOM node are rendered in the cells. The first child is rendered in the top-left corner. Subsequent children are rendered in rows from left to right and top to bottom.

Field Summary
static int
Deprecated.
static int
Deprecated.
static Array<String>
Deprecated.
static int
Deprecated.
static int
Deprecated.
static int
Deprecated.
static int
Deprecated.
Constructor Summary
void
init(strName : String)
The instance initializer.
Method Summary
int
Deprecated.
String
Array<int | String>
Deprecated. Use getRows() and getCols() instead.
int
Deprecated. Use getRows() and getCols() instead.
int
Deprecated.
String
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.LayoutGrid
setBestGuess(LAYOUT : int)
Deprecated.
jsx3.gui.LayoutGrid
setCols(strCols : String, bRepaint : ?)
jsx3.gui.LayoutGrid
setDimensionArray(objArray : Array<int | String>, bRepaint : boolean)
Deprecated. Use setRows() and setCols() instead.
jsx3.gui.LayoutGrid
setOrientation(ORIENTATION : int)
Deprecated. Use setRows() and setCols() instead.
jsx3.gui.LayoutGrid
setRepeat(intCellCount : int)
Deprecated.
jsx3.gui.LayoutGrid
setRows(strRows : String, bRepaint : ?)
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ABSOLUTE

static int ABSOLUTE
Deprecated.
0

ADAPTIVE

static int ADAPTIVE
Deprecated.
1

DEFAULTDIMENSIONS

static Array<String> DEFAULTDIMENSIONS
Deprecated.
["33%","33%","34%"] (default)

DEFAULTORIENTATION

static int DEFAULTORIENTATION
Deprecated.
0 : top-over (--) layout (default)

DEFAULTREPEAT

static int DEFAULTREPEAT
Deprecated.
3 (default)

ORIENTATIONCOL

static int ORIENTATIONCOL
Deprecated.
0 : top-over (--) layout

ORIENTATIONROW

static int ORIENTATIONROW
Deprecated.
1 : side-by-side (|) layout
Constructor Detail

init

void init(strName : String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

getBestGuess

int getBestGuess()
Deprecated.
The LayoutGrid leverages an HTML Table for its on-screen VIEW; this table can use the browser's own adaptive layouts to best adjust to the size of its content; returns one of: jsx3.gui.LayoutGrid.ABSOLUTE, jsx3.gui.LayoutGrid.ADAPTIVE

Returns:

one of: jsx3.gui.LayoutGrid.ABSOLUTE, jsx3.gui.LayoutGrid.ADAPTIVE 

getCols

String getCols()

Returns:

 

Since:

3.4

getDimensionArray

Array<int | String> getDimensionArray()
Deprecated. Use getRows() and getCols() instead.
Returns dimensions for cells in the layoutgrid as a JavaScript array

Returns:

JavaScript array 

getOrientation

int getOrientation()
Deprecated. Use getRows() and getCols() instead.
Returns whether the layout grid will render items top-over (--) or side-by-side (|); returns jsx3.gui.LayoutGrid.ORIENTATIONCOL or jsx3.gui.LayoutGrid.ORIENTATIONROW

Returns:

 

getRepeat

int getRepeat()
Deprecated.
Returns the number of cells to draw before starting a new row/column of cells

Returns:

number of cells to draw before starting a new row/column of cells 

getRows

String getRows()

Returns:

 

Since:

3.4

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setBestGuess

jsx3.gui.LayoutGrid setBestGuess(LAYOUT : int)
Deprecated.
The LayoutGrid leverages an HTML Table for its on-screen VIEW; this table can use the browser's own adaptive layouts to best adjust to the size of its content; returns one of: jsx3.gui.LayoutGrid.ABSOLUTE, jsx3.gui.LayoutGrid.ADAPTIVE; returns reference to self to facilitate method chaining

Parameters:

LAYOUTjsx3.gui.LayoutGrid.ABSOLUTE if null; one of: jsx3.gui.LayoutGrid.ABSOLUTE, jsx3.gui.LayoutGrid.ADAPTIVE

Returns:

this object 

setCols

jsx3.gui.LayoutGrid setCols(strCols : String, bRepaint : ?)

Parameters:

strCols
bRepaint

Returns:

this object. 

Since:

3.4

setDimensionArray

jsx3.gui.LayoutGrid setDimensionArray(objArray : Array<int | String>, bRepaint : boolean)
Deprecated. Use setRows() and setCols() instead.
Sets dimensions for cells in the layoutgrid; returns reference to self to facilitate method chaining

Parameters:

objArrayif null, no sizing information will be applied to the cells; otherwise: valid JavaScript array with number of items equal to the value of this.getRepeat();
bRepaintfalse if null; if true, the new dimensions will be applied to the on-screen view without a repaint, allowing for faster performance than by following this call with a repaint() call

Returns:

this object 

setOrientation

jsx3.gui.LayoutGrid setOrientation(ORIENTATION : int)
Deprecated. Use setRows() and setCols() instead.
Sets whether the layout grid will render items top-over (--) or side-by-side (|); returns reference to self to facilitate method chaining

Parameters:

ORIENTATIONif null, jsx3.gui.LayoutGrid.DEFAULTORIENTATION will be used; otherwise, one of: jsx3.gui.LayoutGrid.ORIENTATIONROW or jsx3.gui.LayoutGrid.ORIENTATIONCOL

Returns:

this object 

setRepeat

jsx3.gui.LayoutGrid setRepeat(intCellCount : int)
Deprecated.
Sets the number of cells to draw before starting a new row/column of cells; returns reference to self to facilitate method chaining

Parameters:

intCellCountnumber of cells to draw before starting a new row/column of cells; since null is not allowed, pass 0 if you don't want any child elements to render to the on-screen VIEW

Returns:

this object 

setRows

jsx3.gui.LayoutGrid setRows(strRows : String, bRepaint : ?)

Parameters:

strRows
bRepaint

Returns:

this object. 

Since:

3.4

jsx3.gui

class List

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.List

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

Direct Known Subclasses:

jsx3.gui.Grid

class List
extends jsx3.gui.Block
Deprecated. Use jsx3.gui.Matrix instead.
The jsx3.gui.List class supports sorting, resizing, reordering, selection, discontinuous selection, key and mouse navigation, etc. Its data is accessed via the CDF interface.

See Also:

jsx3.gui.Matrix

Field Summary
static String
#F3F2F4
static String
#c8cfd8
static String
background-image:url(JSX/images/list/header.gif);
static int
20
static String
jsx30list_r1
static String
Deprecated.
static int
1
static int
2
static String
#2050df
static String
url(JSX/images/list/select.gif)
static int
0
static String
ascending
static String
descending
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
void
appendRow(objMasterRecord : Object, strID : String)
Appends a new row to the end of the list and adds a corresponding record to the CDF source XML.
jsx3.gui.List
Deprecated. use resetXslCacheData() instead.
jsx3.gui.List
Deselects all selected CDF records of this list.
jsx3.gui.List
deselectRecord(strRecordId : String)
Deselects a CDF record of this list.
void
Deprecated. use setValue() or deselectAllRecords() instead.
void
Deprecated. use setValue() or deselectAllRecords() instead.
jsx3.gui.List
doDeselect(strRecordId : String, bVIEW : boolean)
Deprecated. use setValue() or deselectRecord() instead.
void
doExecute(strRecordId : String)
Deprecated. use executeRecord() instead.
jsx3.gui.List
doSelect(strRecordId : String, bVIEW : boolean, bNoEvent : boolean, bReveal : ?)
Deprecated. use setValue() or selectRecord() instead.
void
doSort(intSortDir : String)
Sorts this list according to the current sort path.
int
validates the list; if the list is set to 'required', a selection must be made to pass validation.
void
executeRecord(strRecordId : String)
Evaluates the JavaScript code in the jsxexecute attribute of one CDF record of this list.
jsx3.gui.List
focusRecord(strRecordId : String)
Gives cursor focus to a row in the list.
HTMLElement
Returns a handle to the active TR for the list.
int
Deprecated. Replaced by getGrowBy which returns an integer argument rather than a boolean.
String
Returns the CSS color for the header row (for example, "#ffffff").
String
Returns the CSS background property for the header row (for example, "background-image:url(abc.gif)").
int
Returns whether the columns in the list can be re-ordered via user interaction.
void
Deprecated. Renamed to getResizable.
int
Returns whether the list will render with sortable columns.
int
Returns whether or not a new row will be appended to the VIEW when a new record is added to the CDF document for the List.
int
Returns the height of the header row in pixels.
int
Returns the selection type of this list.
int
Returns whether columns in this list can be resized.
void
Deprecated. Renamed to getResizable.
Array<String>
Returns the ids of the selected records of this list.
jsx3.util.List<jsx3.xml.Entity>
Returns the collection of selected records.
int
Returns the zero-based index of column to sort on.
String
Returns the direction (jsx3.gui.List.SORTASCENDING or jsx3.gui.List.SORTDESCENDING) for the sorted column; if no direction specified, ascending is returned
String
Returns the selection path for XSLT to use when sorting output.
String
Returns the data type to be used for sorting this list.
String | Array<String>
Returns the jsxid of the selected record if this list is a single-select list or an array of the the jsxids of the selected records if this list is a multi-select list.
static String
Deprecated.
int
Returns whether or not the rows in the grid will support text-wrapping and expand to display their wrapped content OR be a fixed height.
jsx3.xml.Document
Returns xslt for the List, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default
boolean
isSelected(strRecordId : String)
Returns whether or not the given record is selected (true/false)
static void
onCheck(strId : String, strPropName : String, objGUI : HTMLElement, bToggle : boolean, objArray : Object)
Deprecated.
static void
onDelete(strId : String, objGUI : HTMLElement)
Static function that can be called from XSLT-generated content in a list cell to delete a row from the CDF of a list instance.
static void
onRadio(strId : String, strPropName : String, objGUI : HTMLElement, bSelect : boolean, objArray : Object)
provides function that can be called from XSLT-generated content in a list cell.
String
Returns the DHTML, used for this object's on-screen VIEW
void
redrawRecord(strRecordId : String, intAction : int)
List implementation.
void
Repaints the body portion of the list (the data rows), retaining the scroll position in the list whereas repainting the entire list would reset scroll position.
void
Repaints the head portion of the list (the header row).
void
revealRecord(strRecordId : String, objJSX : jsx3.gui.Block)
Reveals a record by scrolling any ancestor blocks as necessary.
jsx3.gui.List
selectRecord(strRecordId : String)
Selects a CDF record of this list.
void
setAutoExpand(bExpand : int)
Deprecated. Replaced by setGrowBy which takes an integer argument rather than a boolean one.
jsx3.gui.List
Sets the CSS color for the header row (for example, #ffffff)
jsx3.gui.List
Sets the CSS background property (can be a composite of varoius CSS-related bg properties)
jsx3.gui.List
setCanReorder(intReorder : int)
Sets whether the columns in the list can be re-ordered via user interaction with the VIEW
void
Deprecated. Renamed to setResizable.
jsx3.gui.List
setCanSort(SORT : int)
Sets whether the list will render with sortable columns.
jsx3.gui.List
setGrowBy(intGrow : int)
Sets whether or not a new row will be appended to the VIEW when a new record is added to the CDF document for the List.
jsx3.gui.List
setHeaderHeight(intHeight : int)
Sets the height of the header row in pixels.
jsx3.gui.List
setMultiSelect(intMulti : int)
Sets the selection type of this list.
jsx3.gui.List
setResizable(BOOLEAN : int)
Sets whether columns in this list can be resized.
void
Deprecated. Renamed to setResizable.
jsx3.gui.List
setSortColumn(intColumnIndex : int)
Sets the zero-based index of column to sort on and executes the sort.
jsx3.gui.List
setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.
jsx3.gui.List
setSortPath(strPath : String)
Sets the index for the column that the data will be sorted on; returns a ref to self;
jsx3.gui.List
setSortType(strDataType : String)
Sets the data type for the list.
jsx3.gui.List
setValue(strRecordId : String | Array<String>)
Sets the selected records for this list.
jsx3.gui.List
setWrap(WRAP : int)
Sets whether or not the rows in the grid will support text-wrapping and expand to display their wrapped content OR be a fixed height.
void
updateRow(strRecordId : String)
Updates the DHTML (VIEW) for an existing row within a list, circumventing a full table repaint by updating the row directly.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#F3F2F4

DEFAULTBACKGROUNDCOLORHEAD

static String DEFAULTBACKGROUNDCOLORHEAD
#c8cfd8

DEFAULTBACKGROUNDHEAD

static String DEFAULTBACKGROUNDHEAD
background-image:url(JSX/images/list/header.gif);

DEFAULTHEADERHEIGHT

static int DEFAULTHEADERHEIGHT
20

DEFAULTROWCLASS

static String DEFAULTROWCLASS
jsx30list_r1

DEFAULTXSLURL

static String DEFAULTXSLURL
Deprecated.
JSX/xsl/[?fx]/jsx30list.xsl (default)

MULTI

static final int MULTI
1

NOTSELECTABLE

static final int NOTSELECTABLE
2

RESIZEBARBGCOLOR

static String RESIZEBARBGCOLOR
#2050df

SELECTBGIMAGE

static String SELECTBGIMAGE
url(JSX/images/list/select.gif)

SINGLE

static final int SINGLE
0

SORTASCENDING

static final String SORTASCENDING
ascending

SORTDESCENDING

static final String SORTDESCENDING
descending
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

appendRow

void appendRow(objMasterRecord : Object, strID : String)
Appends a new row to the end of the list and adds a corresponding record to the CDF source XML. This method requires that at least one CDF record already be present to use as a master to clone from if the objMasterRecord parameter is null.

Parameters:

objMasterRecordJavaScript object containing at least the field jsxid.
strIDif provided this id will be used as the id (jsxid) for objMasterRecord. If null, a unique, system-generated key will be used.

clearXSL

jsx3.gui.List clearXSL()
Deprecated. use resetXslCacheData() instead.
List instances typically start with a baseline, system XSL file which is then extended at run-time to include the output markup specific to the child columns; calling this method will remove the document from the cache, effectively causing the template to reset; returns ref to self

Returns:

this object 

See Also:


deselectAllRecords

jsx3.gui.List deselectAllRecords()
Deselects all selected CDF records of this list.

Returns:

this object  

deselectRecord

jsx3.gui.List deselectRecord(strRecordId : String)
Deselects a CDF record of this list. The item will be un-highlighted in the view and the CDF data will be updated accordingly.

Parameters:

strRecordIdthe jsxid of the record to deselect.

Returns:

this object  

deselectRecords

void deselectRecords()
Deprecated. use setValue() or deselectAllRecords() instead.
Deselects all selected records of this list. This method updates both the model and the view.

See Also:

,

doClearSelections

void doClearSelections()
Deprecated. use setValue() or deselectAllRecords() instead.
Deselects all selected records of this list. This method updates both the model and the view.

See Also:

,

doDeselect

jsx3.gui.List doDeselect(strRecordId : String, bVIEW : boolean)
Deprecated. use setValue() or deselectRecord() instead.
Deselects a given record for the list. Invokes the SELECT and CHANGE model events only under the deprecated 3.0 model event protocol.

Parameters:

strRecordId'jsxid' value for the record node (according to the CDF) to select in the DATA MODEL
bVIEWtrue if null; if true, the selection state in the VIEW will be updated to reflect the selection within the MODEL

Returns:

this object 

See Also:

,

doExecute

void doExecute(strRecordId : String)
Deprecated. use executeRecord() instead.
Executes any bound code for a record of this list specified by the strRecordId parameter. If this parameter is omitted the code of any currently selected records is executed. Invokes the EXECUTE model event only under the deprecated 3.0 model event protocol.

Parameters:

strRecordId'jsxid' value for the record node (according to the CDF) to execute

See Also:


doSelect

jsx3.gui.List doSelect(strRecordId : String, bVIEW : boolean, bNoEvent : boolean, bReveal : ?)
Deprecated. use setValue() or selectRecord() instead.
Selects a given record for the list. Invokes the SELECT and CHANGE model events only under the deprecated 3.0 model event protocol.

Parameters:

strRecordId'jsxid' value for the record node (according to the CDF) to select in the DATA MODEL
bVIEWtrue if null; if true, the selection state in the VIEW will be updated to reflect the selection within the MODEL
bNoEventif true, then don't invoke a selection event
bReveal

Returns:

this object 

See Also:

,

doSort

void doSort(intSortDir : String)
Sorts this list according to the current sort path. If no sort direction is specified, the value will be toggled.

Parameters:

intSortDirSORTASCENDING or SORTDESCENDING.

See Also:

,

doValidate

int doValidate()
validates the list; if the list is set to 'required', a selection must be made to pass validation. Otherwise, a list will always pass validation

Returns:

one of: jsx3.gui.Form.STATEINVALID or jsx3.gui.Form.STATEVALID  

Overrides:


executeRecord

void executeRecord(strRecordId : String)
Evaluates the JavaScript code in the jsxexecute attribute of one CDF record of this list.

Parameters:

strRecordIdthe jsxid of the CDF record to execute.

focusRecord

jsx3.gui.List focusRecord(strRecordId : String)
Gives cursor focus to a row in the list.

Parameters:

strRecordIdthe jsxid value for the record node (according to the CDF) to give focus to.

Returns:

this object  

getActiveRow

HTMLElement getActiveRow()
Returns a handle to the active TR for the list.

Returns:

the JavaScript DOM object or null if no row is active.  

getAutoExpand

int getAutoExpand()
Deprecated. Replaced by getGrowBy which returns an integer argument rather than a boolean.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE 

See Also:


getBackgroundColorHead

String getBackgroundColorHead()
Returns the CSS color for the header row (for example, "#ffffff"). If this value is not set (null) the list will render with the default value of jsx3.gui.List.DEFAULTBACKGROUNDCOLORHEAD.

Returns:

CSS color  

getBackgroundHead

String getBackgroundHead()
Returns the CSS background property for the header row (for example, "background-image:url(abc.gif)"). If this value is not set (null) the list will render with the default value of jsx3.gui.List.DEFAULTBACKGROUNDHEAD.

Returns:

CSS background property  

getCanReorder

int getCanReorder()
Returns whether the columns in the list can be re-ordered via user interaction. The default value is jsx3.Boolean.TRUE.

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getCanResize

void getCanResize()
Deprecated. Renamed to getResizable.

See Also:


getCanSort

int getCanSort()
Returns whether the list will render with sortable columns.

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getGrowBy

int getGrowBy()
Returns whether or not a new row will be appended to the VIEW when a new record is added to the CDF document for the List. In the case of a grid, a new row is also appended when the last row in the grid gets cursor focus.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getHeaderHeight

int getHeaderHeight()
Returns the height of the header row in pixels. If this value is not set (null) the list will render with the default value of jsx3.gui.List.DEFAULTHEADERHEIGHT.

Returns:

 

getMultiSelect

int getMultiSelect()
Returns the selection type of this list.

Returns:

MULTI, SINGLE, or NOTSELECTABLE.  

getResizable

int getResizable()
Returns whether columns in this list can be resized. The default value is jsx3.Boolean.TRUE.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.TRUE  

getResizeable

void getResizeable()
Deprecated. Renamed to getResizable.

See Also:


getSelectedIds

Array<String> getSelectedIds()
Returns the ids of the selected records of this list.

Returns:

JavaScript array of stings  

getSelectedNodes

jsx3.util.List<jsx3.xml.Entity> getSelectedNodes()
Returns the collection of selected records.

Returns:

 

getSortColumn

int getSortColumn()
Returns the zero-based index of column to sort on.

Returns:

zero-based index of child column  

getSortDirection

String getSortDirection()
Returns the direction (jsx3.gui.List.SORTASCENDING or jsx3.gui.List.SORTDESCENDING) for the sorted column; if no direction specified, ascending is returned

Returns:

one of: jsx3.gui.List.SORTASCENDING or jsx3.gui.List.SORTDESCENDING  

getSortPath

String getSortPath()
Returns the selection path for XSLT to use when sorting output. Typically this is simply the name of the attribute preceded by '@' (i.e., @jsxtext, @social, @phone, etc); if no value exists (e.g., null), an empty string is returned

Returns:

selection path (xpath / xsl query)  

getSortType

String getSortType()
Returns the data type to be used for sorting this list. This value is either the one explicitly set with setSortType() or the data type of the current sort.

Returns:

jsx3.gui.Column.TYPETEXT or jsx3.gui.Column.TYPENUMBER  

getValue

String | Array<String> getValue()
Returns the jsxid of the selected record if this list is a single-select list or an array of the the jsxids of the selected records if this list is a multi-select list.

Returns:

 

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getWrap

int getWrap()
Returns whether or not the rows in the grid will support text-wrapping and expand to display their wrapped content OR be a fixed height. The default value is jsx3.Boolean.TRUE.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getXSL

jsx3.xml.Document getXSL()
Returns xslt for the List, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default

Returns:

jsx3.xml.Document instance containing valid XSL stylesheet  

Overrides:


isSelected

boolean isSelected(strRecordId : String)
Returns whether or not the given record is selected (true/false)

Parameters:

strRecordIdjsxid property for the record to check selection state for

Returns:

 

onCheck

static void onCheck(strId : String, strPropName : String, objGUI : HTMLElement, bToggle : boolean, objArray : Object)
Deprecated.
provides function that can be called from XSLT-generated content in a list cell. Allows update of CDF via persistent mask interface (checkbox)

Parameters:

strIdCDF record id (jsxid)
strPropNameCDF attribute name for attribute that stores the value of the checkbox
objGUIbrowser checkbox element (what was checked)
bToggleif true, the checkbox will be toggled via this function and the result will be persisted. if false, the current state of the checkbox will be persisted.
objArray2-element JavaScript array. First element contains the value to insert into the CDF for @strPropName if the checkbox is checked. Second element is for unchecked states.

onDelete

static void onDelete(strId : String, objGUI : HTMLElement)
Static function that can be called from XSLT-generated content in a list cell to delete a row from the CDF of a list instance.

Parameters:

strIdCDF record id (jsxid) for the row to delete.
objGUIbrowser element (the hyperlink was clicked) that is contained in the list instance.

onRadio

static void onRadio(strId : String, strPropName : String, objGUI : HTMLElement, bSelect : boolean, objArray : Object)
provides function that can be called from XSLT-generated content in a list cell. Allows update of CDF via persistent mask interface (radio button); assumes that the nodes in the CDF document have jsxgroupname attributes to distinguish the radio groups

Parameters:

strIdCDF record id (jsxid)
strPropNameCDF attribute name for attribute that stores the value of the radio button
objGUIbrowser radio button element
bSelectif true, the radio button will be forced to a 'selected' state and the result will be persisted. if false, the current state of the radio button will be persisted.
objArray2-element JavaScript array. First element contains the value to insert into the CDF for @strPropName if the checkbox is checked. Second element is for unchecked states.

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


redrawRecord

void redrawRecord(strRecordId : String, intAction : int)
List implementation.

Parameters:

strRecordIdjsxid value for the record node (according to the CDF) to redraw
intActionjsx3.xml.CDF.INSERT, jsx3.xml.CDF.DELETE, or jsx3.xml.CDF.UPDATE.

Overrides:


repaintBody

void repaintBody()
Repaints the body portion of the list (the data rows), retaining the scroll position in the list whereas repainting the entire list would reset scroll position.

repaintHead

void repaintHead()
Repaints the head portion of the list (the header row).

Note that this method will not change the rendered height of the header row. Therefore, after the header height is changed programmatically, repaint() must be called for the list to render properly.

revealRecord

void revealRecord(strRecordId : String, objJSX : jsx3.gui.Block)
Reveals a record by scrolling any ancestor blocks as necessary.

Parameters:

strRecordIdthe id of the record to reveal
objJSXif provided, reveal the record up to this visual block; useful if the list is set to overflow:expand and the containing block is set to overflow:scroll

selectRecord

jsx3.gui.List selectRecord(strRecordId : String)
Selects a CDF record of this list. The item will be highlighted in the view and the CDF data will be updated accordingly. If this list is a multi-select list then this selection will be added to any previous selection.

Parameters:

strRecordIdthe jsxid of the record to select.

Returns:

this object  

setAutoExpand

void setAutoExpand(bExpand : int)
Deprecated. Replaced by setGrowBy which takes an integer argument rather than a boolean one.

Parameters:

bExpandjsx3.Boolean.TRUE or jsx3.Boolean.FALSE.

See Also:


setBackgroundColorHead

jsx3.gui.List setBackgroundColorHead(strBGColor : String)
Sets the CSS color for the header row (for example, #ffffff)

Parameters:

strBGColorCSS color property

Returns:

this object  

setBackgroundHead

jsx3.gui.List setBackgroundHead(strBG : String)
Sets the CSS background property (can be a composite of varoius CSS-related bg properties)

Parameters:

strBGCSS background property

Returns:

this object  

setCanReorder

jsx3.gui.List setCanReorder(intReorder : int)
Sets whether the columns in the list can be re-ordered via user interaction with the VIEW

Parameters:

intReorderone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setCanResize

void setCanResize()
Deprecated. Renamed to setResizable.

See Also:


setCanSort

jsx3.gui.List setCanSort(SORT : int)
Sets whether the list will render with sortable columns.

Parameters:

SORTone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setGrowBy

jsx3.gui.List setGrowBy(intGrow : int)
Sets whether or not a new row will be appended to the VIEW when a new record is added to the CDF document for the List. In the case of a grid, a new row is also appended when the last row in the grid gets cursor focus.

Parameters:

intGrowjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setHeaderHeight

jsx3.gui.List setHeaderHeight(intHeight : int)
Sets the height of the header row in pixels. Set to zero (0) to hide the header row and only render the body rows for the list.

Parameters:

intHeight

Returns:

this object  

setMultiSelect

jsx3.gui.List setMultiSelect(intMulti : int)
Sets the selection type of this list.

Parameters:

intMultiMULTI, SINGLE, or NOTSELECTABLE.

Returns:

this object  

setResizable

jsx3.gui.List setResizable(BOOLEAN : int)
Sets whether columns in this list can be resized.

Parameters:

BOOLEANjsx3.Boolean.TRUE or jsx3.Boolean.TRUE

Returns:

this object  

setResizeable

void setResizeable()
Deprecated. Renamed to setResizable.

See Also:


setSortColumn

jsx3.gui.List setSortColumn(intColumnIndex : int)
Sets the zero-based index of column to sort on and executes the sort. This method fires the AFTER_SORT only under the deprecated 3.0 model event protocol.

Parameters:

intColumnIndexzero-based index of child column

Returns:

this object  

setSortDirection

jsx3.gui.List setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.

Parameters:

intSortDirone of: jsx3.gui.List.SORTASCENDING or jsx3.gui.List.SORTDESCENDING

Returns:

this object  

setSortPath

jsx3.gui.List setSortPath(strPath : String)
Sets the index for the column that the data will be sorted on; returns a ref to self;

Parameters:

strPathselection path (xpath / xsl query)

Returns:

this object  

setSortType

jsx3.gui.List setSortType(strDataType : String)
Sets the data type for the list. This explicit value will override any column data type if set. If it is not set the data type specific to the sort column is used for sorting.

Parameters:

strDataTypejsx3.gui.Column.TYPETEXT or jsx3.gui.Column.TYPENUMBER

Returns:

this object  

setValue

jsx3.gui.List setValue(strRecordId : String | Array<String>)
Sets the selected records for this list. This method clears any current selection state and updates both the view and the model. The strRecordId parameter should be a single value for a single-select list or a list of values for a multi-select list.

Parameters:

strRecordId

Returns:

this object  

Overrides:


setWrap

jsx3.gui.List setWrap(WRAP : int)
Sets whether or not the rows in the grid will support text-wrapping and expand to display their wrapped content OR be a fixed height.

Parameters:

WRAPjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

updateRow

void updateRow(strRecordId : String)
Updates the DHTML (VIEW) for an existing row within a list, circumventing a full table repaint by updating the row directly.

Parameters:

strRecordIdid for the CDF record whose associated on-screen TR needs to be updated.

jsx3.gui

class Matrix

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Matrix

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Matrix
extends jsx3.gui.Block
The Matrix control is the standard visual interface for the Common Data Format (CDF), providing grid and tree-grid functionality that mirrors the the record and attribute structures used by the CDF. Instances of this class can be used to create editable grids, selectable lists, trees, tables, etc. In addtion to providing layout, selection, and editing schemes, the Matrix also provides various paging models to help optimize how (and how much) data is rendered on-screen. The Matrix class is always used in conjunction with jsx3.gui.Matrix.Column, which describes how data for a given series should be rendered on-screen. While the Matrix manages data and user interactions, Column manages the on-screen format for how the data is presented.

Since:

3.2

Nested Class Summary
jsx3.gui.Matrix.BlockMask
The interface that defines the methods that affect the behavior of a composite object used as an edit mask of a matrix column.
jsx3.gui.Matrix.Column
Column control for use as a child of a jsx3.gui.Matrix class
jsx3.gui.Matrix.ColumnFormat
A class that defines the methods required for an object to be used by jsx3.gui.Matrix.Column instances to format cells of data.
jsx3.gui.Matrix.EditMask
The interface defining the methods that affect the behavior of an object used as an edit mask in a matrix column.
Field Summary
static String
jsx:///images/matrix/append.gif
static int
2
static int
1
static int
0
static int
50
static String
static int
20
static String
Deprecated. This value is localized.
static int
18.
static int
3.
static int
250.
static int
50.
static int
20
static String
Deprecated. Renamed to DEFAULTXSLURL.
static String
font-weight:bold
static String
jsx:///images/matrix/file.gif (default)
static String
jsx:///images/matrix/minus.gif (default)
static String
jsx:///images/matrix/plus.gif (default)
static String
jsx:///images/matrix/insert_before.gif
static String
4.
static String
jsxpaintpage.
static int
The outer container is first painted and then the entirety of the data is painted during a second pass
static int
The outer container is first painted.
static int
Default.
static int
The outer container is first painted.
static int
The outer container is painted along with any rows which are immediate children of the rendering context and those descendant rows that have an open path to the context node.
static String
jsx:///images/matrix/select.gif
static int
2
static int
1 (default)
static int
0
static String
ascending
static String
jsx:///images/matrix/sort_asc.gif (default)
static String
descending
static String
jsx:///images/matrix/sort_desc.gif (default)
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
void
adoptChild(objChild : jsx3.app.Model, bRepaint : boolean, bForce : boolean)
Instance override
void
commitAutoRowSession(objEvent : jsx3.gui.Event, intCellIndex : int)
Commits any active autorow session.
jsx3.xml.Entity
deleteRecord(strRecordId : String, bRedraw : boolean)
Removes a record from the XML data source of this object.
void
Deselects all selected CDF records.
void
deselectRecord(strRecordId : String)
Deselects a CDF record within the Matrix.
void
doSort(intSortDir : String)
Sorts according to the current sort path.
int
STATEINVALID is returned if the required property of this control is true and no selection is made.
void
executeRecord(strRecordId : String)
Evaluates the JavaScript code in the jsxexecute attribute of one CDF record of this list.
void
focusCellById(strCdfId : String, strAttName : String)
Applies focus to the on-screen cell that corresponds to the intersection of the element in the CDF source document identified by strCdfId, and the first column mapped to strAttName.
void
focusCellByIndex(strCdfId : String, intCellIndex : int)
Applies focus to the on-screen cell that corresponds to the intersection of the element in the CDF source document identified by strCdfId, and the cell at the given index.
void
focusRowById(strCdfId : String)
Applies focus to the on-screen row that corresponds to the element in the CDF source document identified by strCdfId.
int
Returns whether or not an 'auto append' row will be rendered, allowing the user to automatically add new rows to the instance.
Object
Returns an object array of name/value pairs representing the current auto row session.
String
Returns CSS property value(s) for a border (border: solid 1px #000000)
int
Returns whether the column children can be reordered via user interaction.
int
Returns whether the list will render with sortable columns.
HTMLElement
getContentElement(strCdfId : String, strAttName : String)
Returns the HTML element that represents the intersection of the row identified by strCdfId and the first column mapped to the named CDF attribute, strAttName.
int
getFixedColumnIndex(strDefault : String)
Returns the zero-based index of the on-screen column(s), to the left of which will be fixed and cannot be reordered.
String
getFocusStyle(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus
String
Returns CSS property value(s) for a border (border: solid 1px #000000)
int
getHeaderHeight(strDefault : String)
Returns the height of the header row in pixels.
String
getIcon(strDefault : String)
Returns the icon to use for those CDF records that do not explicitly specify an icon via the jsximg attribute
String
getIconMinus(strDefault : String)
Returns the icon to use when the given tree node is in an open state.
String
getIconPlus(strDefault : String)
Returns the icon to use when the given tree node is in a closed state.
int
getPagingModel(strDefault : String)
Returns how data should be painted on-screen.
int
getPanelPoolSize(strDefault : String)
Returns the number panels (a panel contains a collection of rows--getRowsPerPanel()) that should be part of the pool.
int
getPanelQueueSize(strDefault : String)
Sets the number of panels that are allowed in the queue waiting to be painted.
int
getReaperInterval(strDefault : String)
Returns the the number of milliseconds to wait before checking for inactive panels to garbage collect.
int
getRenderNavigators(strDefault : String)
Returns whether or not to render the navigation controls that are applied to the first column when rendering model is hierarchical.
String
getRenderingContext(strDefault : String)
Returns the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.
String
getRenderingModel(strDefault : String)
Returns the rendering model (how rows will be painted on-screen).
int
Returns whether or not this column can be resized by the user.
int
getRowHeight(strDefault : String)
Returns the row height
int
getRowsPerPanel(strDefault : String)
Returns the number of rows each panel should contain.
int
Returns whether or not the column widths should be adjusted (decremented) such that all columns fit within the viewport.
int
getScrollInfoLabel(strDefault : String)
Returns the info label to display when scrolling a paged instance, in order to show the scroll position.
int
Returns the horizontal scroll position of the list.
int
Returns the vertical scroll position.
Array<String>
Returns the jsxid(s) for the selected record(s).
jsx3.util.List<jsx3.xml.Entity>
Returns the collection of selected records.
String
getSelectionBG(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus
int
getSelectionModel(strDefault : String)
Returns the selection model.
String
Returns the direction (jsx3.gui.Matrix.SORT_ASCENDING or jsx3.gui.Matrix.SORT_DESCENDING) for the sorted column; if no direction specified, ascending is returned
String
Returns the name of the CDF attribute to sort on.
String
Returns the data type to be used for sorting this list.
Array
Returns an array of all jsxid attributes in the source CDF in the order they would appear if painted on-screen
int
Returns whether or not to supress display of the horizontal scrollbar.
int
Returns whether or not to supress display of the vertical scrollbar.
String | Array<String>
Returns an array of selected values (or empty array) if the selection model is jsx3.gui.Matrix.SELECTION_MULTI_ROW.
jsx3.xml.Document
Deprecated. Per-instance control of the XSL template is deprecated
void
insertBefore(objMoveChild : jsx3.app.Model, objPrecedeChild : jsx3.app.Model, bRepaint : boolean)
Assigns objMoveChild as the previousSibling of objPrecedeChild
jsx3.xml.CDF
insertRecordProperty(strRecordId : String, strPropName : String, strPropValue : String, bRedraw : boolean)
Inserts a new property into an existing record with jsxid equal to strRecordId.
String
Returns the DHTML, used for this object's on-screen VIEW
void
paintChild(objJSX : jsx3.app.Model, bGroup : ?)
inserts DHTML (as string) into IE's on-screen DOM as a child of the object's on-screen VIEW
void
redrawCell(strRecordId : String, objColumn : jsx3.gui.Matrix.Column, bSuppressTriggers : boolean, objTRXML : jsx3.xml.Entity)
Updates the on-screen cell to reflect the value in the CDF document to which the cell is mapped.
void
redrawMappedCells(strRecordId : String, strAttName : String)
Updates the on-screen cell to reflect the value in the CDF document to which the cell is mapped.
void
redrawRecord(strRecordId : String, intAction : int, bRecurse : boolean)
Matrix implementation.
String
Updates the view of this object by calling paint() and replacing the current view with the returned HTML.
void
Paints only the data rows.
void
Repaints the header row for improved runtime efficiency.
void
Removes the XML source document stored under the XML ID of this object from the server cache.
void
resetFocusContext(strId : ?)
Removes the focus style from whichever cell is designated to have focus context.
void
Ends any existing edit session and hides the active mask.
void
Removes the XML source document stored under the XML ID of this object from the server cache.
void
revealRecord(strRecordId : String)
Reveals a record by toggling parent nodes open (if rendering hierarcally) and scrolling the record into view.
void
selectRecord(strRecordId : String)
Selects a CDF record of this list.
void
setAutoRow(intBoolean : int)
Sets whether or not an 'auto append' row will be rendered, allowing the user to automatically add new rows to the instance.
jsx3.gui.Block
setBodyBorder(strCSS : String, bSuppressRepaint : boolean)
Sets CSS property value(s) for a border (border: solid 1px #000000).
void
setCanReorder(REORDER : int)
Sets whether the columns in the list can be re-ordered via user interaction with the VIEW
void
setCanSort(SORT : int)
Sets whether the list will render with sortable columns.
void
setFixedColumnIndex(intIndex : int)
Sets the zero-based index of the on-screen column(s), to the left of which will be fixed and cannot be reordered.
void
setFocusStyle(strCSS : String)
Sets the CSS string to apply to a Row/Cell when it has focus.
void
Sets CSS property value(s) for a border on the header row (border: solid 1px #000000).
void
setHeaderHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the height of the header row in pixels.
void
setIcon(strURL : String)
Sets the icon to use for those CDF records that do not explicitly specify an icon via the jsximg attribute
void
setIconMinus(strURL : String)
Sets the icon to use when the given tree node is in an open state.
void
setIconPlus(strURL : String)
Sets the icon to use when the given tree node is in a closed state.
void
setPagingModel(intModel : int)
Sets how data should be painted on-screen.
void
setPanelPoolSize(intCount : int)
Sets the number panels (a panel contains a collection of rows--getRowsPerPanel()) that should be part of the pool.
void
setPanelQueueSize(intCount : int)
Sets the number of panels that are allowed in the queue waiting to be painted.
void
setReaperInterval(intInterval : int)
Sets the the number of milliseconds to wait before checking for inactive panels to garbage collect.
void
setRenderNavigators(intTrueFalse : int, bSuppressRepaint : boolean)
Sets whether or not to render the navigation controls on the first column when being rendered in hierarchical mode.
void
setRenderingContext(strJsxId : String, bSuppressRepaint : boolean)
Sets the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.
void
setRenderingModel(MODEL : String, bSuppressRepaint : boolean)
Sets the rendering model (how rows will be painted on-screen).
void
setResizable(RESIZE : int)
Sets whether or not this column can be resized by the user.
void
setRowHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the on-screen row height.
void
setRowsPerPanel(intCount : int, bSuppressRepaint : boolean)
Sets the number of rows each panel should contain.
void
setScaleWidth(intBoolean : int)
Sets whether or not the column widths should be adjusted such that all columns visually display within the viewport.
void
Sets the standard info label to display when scrolling to show the scroll position.
void
setScrollLeft(intScrollLeft : int)
Sets the horizontal scroll position.
void
setScrollTop(intScrollTop : int, objGUI : HTMLElement)
Sets the vertical scroll position.
void
Sets the URL for the image to use (as the repeating background image) to denote selection.
void
setSelectionModel(intType : int)
Sets the selection model
void
setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.
void
setSortPath(strAttr : String)
Sets the name of the CDF attribute to sort on.
void
setSortType(DATATYPE : String)
Sets the data type for the list.
void
setSuppressHScroller(intTrueFalse : int)
Sets whether or not to supress display of the horizontal scrollbar.
void
setSuppressVScroller(intTrueFalse : int, bSuppressRepaint : boolean)
Sets whether or not to supress display of the vertical scrollbar.
jsx3.gui.Matrix
setValue(strId : String | Array<String>)
Sets the value of this matrix.
jsx3.xml.Cacheable
setXMLId(strXMLId : String)
Sets the XML ID of this object.
jsx3.xml.Cacheable
setXMLString(strXML : String)
Sets the XML string of this object.
jsx3.xml.Cacheable
setXMLURL(strXMLURL : String)
Sets the XML URL of this object.
void
Updates the scroll height and scroll position of the vertical scrollbar.
void
toggleItem(strRecordId : String, bOpen : boolean)
Toggles the open/closed state for a node in the Matrix
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLTransformers, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChildren, recalcBox, removeAttribute, removeAttributes, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

APPEND_IMG

static String APPEND_IMG
jsx:///images/matrix/append.gif

AUTOROW_FIRST_ROW

static final int AUTOROW_FIRST_ROW
2

AUTOROW_LAST_ROW

static final int AUTOROW_LAST_ROW
1

AUTOROW_NONE

static final int AUTOROW_NONE
0

AUTO_SCROLL_INTERVAL

static int AUTO_SCROLL_INTERVAL
50

DEFAULTXSLURL

static String DEFAULTXSLURL

DEFAULT_HEADER_HEIGHT

static int DEFAULT_HEADER_HEIGHT
20

DEFAULT_INFO_LABEL

static String DEFAULT_INFO_LABEL
Deprecated. This value is localized.
"Viewing rows {0} to {1} of {2}".
Wildcards are as follows:
  • {0} The index position of the first visible on-screen row
  • {1} The index position of the last visible on-screen row
  • {2} Total count of all records in the list

DEFAULT_PANEL_POOL_COUNT

static int DEFAULT_PANEL_POOL_COUNT
18. number of panels allowed on-screen before destroying the panel most distant from the current panel index

DEFAULT_PANEL_QUEUE_SIZE

static int DEFAULT_PANEL_QUEUE_SIZE
3. number of panels in the paint queue. As new panels are added to the queue to be painted, older, less-relevant panels in the queue are removed

DEFAULT_REAPER_INTERVAL

static int DEFAULT_REAPER_INTERVAL
250. number of milliseconds between the time a new panel is added and the reaper checks for content exceeding jsx3.gui.Matrix.DEFAULT_PANEL_POOL_COUNT

DEFAULT_ROWS_PER_PANEL

static int DEFAULT_ROWS_PER_PANEL
50. number of rows in a given panel

DEFAULT_ROW_HEIGHT

static int DEFAULT_ROW_HEIGHT
20

DEFAULT_XSL_URL

static String DEFAULT_XSL_URL
Deprecated. Renamed to DEFAULTXSLURL.

FOCUS_STYLE

static String FOCUS_STYLE
font-weight:bold

ICON

static String ICON
jsx:///images/matrix/file.gif (default)

ICON_MINUS

static String ICON_MINUS
jsx:///images/matrix/minus.gif (default)

ICON_PLUS

static String ICON_PLUS
jsx:///images/matrix/plus.gif (default)

INSERT_BEFORE_IMG

static String INSERT_BEFORE_IMG
jsx:///images/matrix/insert_before.gif

MINIMUM_COLUMN_WIDTH

static final String MINIMUM_COLUMN_WIDTH
4. minimum width of a column when minimized (set Display to 'none' to completely hide a column)

ON_PAINT_PAGE

static final String ON_PAINT_PAGE
jsxpaintpage. Event to subscribe to each time a page of content is about to be painted on-screen

PAGING_2PASS

static final int PAGING_2PASS
The outer container is first painted and then the entirety of the data is painted during a second pass

PAGING_CHUNKED

static final int PAGING_CHUNKED
The outer container is first painted. Chunked sets of data are painted on-screen during repeated passes until all data is painted

PAGING_OFF

static final int PAGING_OFF
Default. All data is painted at once with the outer container.

PAGING_PAGED

static final int PAGING_PAGED
The outer container is first painted. The first and last panels are painted during a second pass. As the user scrolls, relevant panels are added and unused panels are collected. (NOTE: Requires that row height be fixed.)

PAGING_STEPPED

static final int PAGING_STEPPED
The outer container is painted along with any rows which are immediate children of the rendering context and those descendant rows that have an open path to the context node. All other rows will be fetched when the state for their on-screen parent row is toggled to open.

SELECTION_BG

static String SELECTION_BG
jsx:///images/matrix/select.gif

SELECTION_MULTI_ROW

static final int SELECTION_MULTI_ROW
2

SELECTION_ROW

static final int SELECTION_ROW
1 (default)

SELECTION_UNSELECTABLE

static final int SELECTION_UNSELECTABLE
0

SORT_ASCENDING

static final String SORT_ASCENDING
ascending

SORT_ASCENDING_IMG

static String SORT_ASCENDING_IMG
jsx:///images/matrix/sort_asc.gif (default)

SORT_DESCENDING

static final String SORT_DESCENDING
descending

SORT_DESCENDING_IMG

static String SORT_DESCENDING_IMG
jsx:///images/matrix/sort_desc.gif (default)
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

adoptChild

void adoptChild(objChild : jsx3.app.Model, bRepaint : boolean, bForce : boolean)
Instance override

Parameters:

objChildthe child to adopt
bRepaintif true or null, the object being adopted will be added to the parent's view via the parent's paintChild() method. This parameter is made available for those situations where a loop is executing and multiple objects are being adopted. As view operations are the most CPU intensive, passing false while looping through a collection of child objects to adopt will improve performance. After the last child is adopted, simply call repaint() on the parent to immediately synchronize the view.
bForceif true, the adoption is forced, even if the parent/child don't accept such adoptions (onSetChild() and onSetParent() will still be called)

Overrides:

See Also:


commitAutoRowSession

void commitAutoRowSession(objEvent : jsx3.gui.Event, intCellIndex : int)
Commits any active autorow session.

Parameters:

objEventIf passed, Allows Model Event to fire.
intCellIndexFocus will be applied to the autorow cell at this index (zero-based)

deleteRecord

jsx3.xml.Entity deleteRecord(strRecordId : String, bRedraw : boolean)
Removes a record from the XML data source of this object.

Parameters:

strRecordIdthe jsxid attribute of the data record to remove.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the deleted record.

Returns:

the record removed from the data source or null if no such record found.  

Overrides:


deselectAllRecords

void deselectAllRecords()
Deselects all selected CDF records.

deselectRecord

void deselectRecord(strRecordId : String)
Deselects a CDF record within the Matrix. Both the view and the data model (CDF) will be updated

Parameters:

strRecordIdthe jsxid of the record to deselect.

doSort

void doSort(intSortDir : String)
Sorts according to the current sort path. If no sort direction is specified, the value will be toggled.

Parameters:

intSortDirjsx3.gui.Matrix.SORT_ASCENDING or jsx3.gui.Matrix.SORT_DESCENDING.

See Also:

,

doValidate

int doValidate()
STATEINVALID is returned if the required property of this control is true and no selection is made.

Returns:

jsx3.gui.Form.STATEINVALID or jsx3.gui.Form.STATEVALID.  

Overrides:


executeRecord

void executeRecord(strRecordId : String)
Evaluates the JavaScript code in the jsxexecute attribute of one CDF record of this list.

Parameters:

strRecordIdthe jsxid of the CDF record to execute.

focusCellById

void focusCellById(strCdfId : String, strAttName : String)
Applies focus to the on-screen cell that corresponds to the intersection of the element in the CDF source document identified by strCdfId, and the first column mapped to strAttName.

Parameters:

strCdfIdjsxid property for CDF record
strAttNameattribute name on the CDF record. For example, jsxtext

focusCellByIndex

void focusCellByIndex(strCdfId : String, intCellIndex : int)
Applies focus to the on-screen cell that corresponds to the intersection of the element in the CDF source document identified by strCdfId, and the cell at the given index.

Parameters:

strCdfIdjsxid property for CDF record
intCellIndexzero-based index of cell (on-screen).

focusRowById

void focusRowById(strCdfId : String)
Applies focus to the on-screen row that corresponds to the element in the CDF source document identified by strCdfId. Note that since only cells can receive focus, this method will apply focus to the first cell child in the row.

Parameters:

strCdfIdjsxid property for CDF record

See Also:


getAutoRow

int getAutoRow()
Returns whether or not an 'auto append' row will be rendered, allowing the user to automatically add new rows to the instance.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getAutoRowSession

Object getAutoRowSession()
Returns an object array of name/value pairs representing the current auto row session. When the session is committed, this object will be converted into a CDF Record for the instance.

Returns:

 

getBodyBorder

String getBodyBorder()
Returns CSS property value(s) for a border (border: solid 1px #000000)

Returns:

 

getCanReorder

int getCanReorder()
Returns whether the column children can be reordered via user interaction. If no value is supplied the isntance will allow child columns to be reordered.

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getCanSort

int getCanSort()
Returns whether the list will render with sortable columns. If null or jsx3.Boolean.TRUE, the instance is sortable.

Returns:

 

getContentElement

HTMLElement getContentElement(strCdfId : String, strAttName : String)
Returns the HTML element that represents the intersection of the row identified by strCdfId and the first column mapped to the named CDF attribute, strAttName.

Parameters:

strCdfIdjsxid property for CDF record
strAttNameattribute name on the CDF record. For example, jsxtext

Returns:

 

getFixedColumnIndex

int getFixedColumnIndex(strDefault : String)
Returns the zero-based index of the on-screen column(s), to the left of which will be fixed and cannot be reordered. For example, if this value is set to 1, the first column can never be reordered and will always remain the first column. If this value is set to 2, the first two columns will be fixed. Setting this value to 0 is effectively the same as setting it to null

Parameters:

strDefaultThe default value to use if null

Returns:

positive integer  

getFocusStyle

String getFocusStyle(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus

Parameters:

strDefaultThe default value to use if null (Matrix.FOCUS_STYLE)

Returns:

 

getHeaderBorder

String getHeaderBorder()
Returns CSS property value(s) for a border (border: solid 1px #000000)

Returns:

 

getHeaderHeight

int getHeaderHeight(strDefault : String)
Returns the height of the header row in pixels. If this value is not set (null), the list will render with the default value of jsx3.gui.Matrix.DEFAULT_HEADER_HEIGHT.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getIcon

String getIcon(strDefault : String)
Returns the icon to use for those CDF records that do not explicitly specify an icon via the jsximg attribute

Parameters:

strDefaultThe default value to use if null

Returns:

URL for icon to use. If null, jsx3.gui.Matrix.ICON will be applied when rendered.  

getIconMinus

String getIconMinus(strDefault : String)
Returns the icon to use when the given tree node is in an open state.

Parameters:

strDefaultThe default value to use if null

Returns:

URL for icon. If null, jsx3.gui.Matrix.ICON_MINUS will be applied when rendered.  

getIconPlus

String getIconPlus(strDefault : String)
Returns the icon to use when the given tree node is in a closed state.

Parameters:

strDefaultThe default value to use if null

Returns:

URL for icon to use. If null, jsx3.gui.Matrix.ICON_PLUS will be applied when rendered.  

getPagingModel

int getPagingModel(strDefault : String)
Returns how data should be painted on-screen. If no value is specified, jsx3.gui.Matrix.PAGING_OFF will be applied. Note that the rendering model limits the available paging models:
  • Matrix.PAGING_OFF: Paint everthing to screen at once (container and data) (rendering model: all)
  • Matrix.PAGING_2PASS: Paint outer container and then perform a second pass to paint the data. (rendering model: deep, shallow)
  • Matrix.PAGING_CHUNKED: Paint outer container and then perform repeated paints until all data has been painted, regardless of scroll position. (rendering model: deep, shallow)
  • Matrix.PAGING_PAGED: Paint outer container. Paint First and last panels during second pass. Paint relevant panels when user scrolls to a given position. Discard excess panels. (rendering model: deep, shallow)
  • Matrix.PAGING_STEPPED: Paint root nodes and any open descendants. Paint others as they are toggled open. (rendering model: hierarchical)

Parameters:

strDefaultThe default value to use if null

Returns:

 

See Also:


getPanelPoolSize

int getPanelPoolSize(strDefault : String)
Returns the number panels (a panel contains a collection of rows--getRowsPerPanel()) that should be part of the pool. If a panel count greater than this value exists, the panels furthest away (as calculated by the scroll position) from the active panel will be destroyed. If this value is null, the value defined by the constant, jsx3.gui.Matrix.DEFAULT_PANEL_POOL_COUNT, will be used.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getPanelQueueSize

int getPanelQueueSize(strDefault : String)
Sets the number of panels that are allowed in the queue waiting to be painted. If null, the default value will be used: jsx3.gui.Matrix.DEFAULT_PANEL_QUEUE_SIZE Note that this is different from the number of painted panels allowed on screen (e.g., getPanelPoolSize()).

Parameters:

strDefaultThe default value to use if null

Returns:

 

getReaperInterval

int getReaperInterval(strDefault : String)
Returns the the number of milliseconds to wait before checking for inactive panels to garbage collect. If null, the default value will be used: jsx3.gui.Matrix.DEFAULT_REAPER_INTERVAL

Parameters:

strDefaultThe default value to use if null

Returns:

 

getRenderNavigators

int getRenderNavigators(strDefault : String)
Returns whether or not to render the navigation controls that are applied to the first column when rendering model is hierarchical. When not set the navigators are rendered.

Parameters:

strDefaultThe default value to use if null

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getRenderingContext

String getRenderingContext(strDefault : String)
Returns the jsxid of the CDF record that will serve as the origin when rendering the data on-screen. If not set, the id, jsxroot, (which is the id for the root node, <data>) will be used.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getRenderingModel

String getRenderingModel(strDefault : String)
Returns the rendering model (how rows will be painted on-screen). If not set, the instance will render deep, meaning all descendants of the rendering context will be painted on-screen.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getResizable

int getResizable()
Returns whether or not this column can be resized by the user. If not set, the column will be assumed resizable

Returns:

 

getRowHeight

int getRowHeight(strDefault : String)
Returns the row height

Parameters:

strDefaultThe default value to use if null

Returns:

 

getRowsPerPanel

int getRowsPerPanel(strDefault : String)
Returns the number of rows each panel should contain. If null, the default value will be used: jsx3.gui.Matrix.DEFAULT_ROWS_PER_PANEL

Parameters:

strDefaultThe default value to use if null

Returns:

 

getScaleWidth

int getScaleWidth()
Returns whether or not the column widths should be adjusted (decremented) such that all columns fit within the viewport. If null or jsx3.Boolean.FALSE, scale width will not be used and the column widths will render fully, displaying a horizontal scrollbar when necessary. In such a case, all wildcard columns (e.g., *) will be resolved to the value, jsx3.gui.Matrix.Column.DEFAULT_WIDTH.

Returns:

 

getScrollInfoLabel

int getScrollInfoLabel(strDefault : String)
Returns the info label to display when scrolling a paged instance, in order to show the scroll position.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getScrollLeft

int getScrollLeft()
Returns the horizontal scroll position of the list.

Returns:

a non-negative number  

getScrollTop

int getScrollTop()
Returns the vertical scroll position.

Returns:

a non-negative number  

getSelectedIds

Array<String> getSelectedIds()
Returns the jsxid(s) for the selected record(s). Equivalent to this.getValue() except that the return value is always an Array.

Returns:

JavaScript array of stings  

getSelectedNodes

jsx3.util.List<jsx3.xml.Entity> getSelectedNodes()
Returns the collection of selected records.

Returns:

 

getSelectionBG

String getSelectionBG(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus

Parameters:

strDefaultThe default value to use if null (Matrix.SELECTION_BG)

Returns:

 

getSelectionModel

int getSelectionModel(strDefault : String)
Returns the selection model. If no selection type is specified, the instance will employ single row selection (jsx3.gui.Matrix.SELECTION_ROW)

Parameters:

strDefaultThe default value to use if null

Returns:

 

getSortDirection

String getSortDirection()
Returns the direction (jsx3.gui.Matrix.SORT_ASCENDING or jsx3.gui.Matrix.SORT_DESCENDING) for the sorted column; if no direction specified, ascending is returned

Returns:

one of: jsx3.gui.Matrix.SORT_ASCENDING or jsx3.gui.Matrix.SORT_DESCENDING  

getSortPath

String getSortPath()
Returns the name of the CDF attribute to sort on. If no value is set an empty string is returned by default.

Returns:

 

See Also:


getSortType

String getSortType()
Returns the data type to be used for sorting this list. This value is either the one explicitly set with setSortType() or the data type of the current sort.

Returns:

jsx3.gui.Matrix.Column.TYPE_TEXT or jsx3.gui.Matrix.Column.TYPE_NUMBER  

getSortedIds

Array getSortedIds()
Returns an array of all jsxid attributes in the source CDF in the order they would appear if painted on-screen

Returns:

 

getSuppressHScroller

int getSuppressHScroller(strDefault : String)
Returns whether or not to supress display of the horizontal scrollbar. When not set, the scrollbar will display as needed.

Parameters:

strDefaultThe default value to use if null

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getSuppressVScroller

int getSuppressVScroller(strDefault : String)
Returns whether or not to supress display of the vertical scrollbar. When not set, the scrollbar will display as needed.

Parameters:

strDefaultThe default value to use if null

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getValue

String | Array<String> getValue()
Returns an array of selected values (or empty array) if the selection model is jsx3.gui.Matrix.SELECTION_MULTI_ROW. Returns a string (or null) for the other selection models

Returns:

 

Overrides:


getXSL

jsx3.xml.Document getXSL()
Deprecated. Per-instance control of the XSL template is deprecated
Returns XSLT, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default

Returns:

jsx3.xml.Document instance containing valid XSL stylesheet 

Overrides:


insertBefore

void insertBefore(objMoveChild : jsx3.app.Model, objPrecedeChild : jsx3.app.Model, bRepaint : boolean)
Assigns objMoveChild as the previousSibling of objPrecedeChild

Parameters:

objMoveChildthe one being moved
objPrecedeChildthe one to insert before
bRepaintif false the repaint will be suppressed

Overrides:


insertRecordProperty

jsx3.xml.CDF insertRecordProperty(strRecordId : String, strPropName : String, strPropValue : String, bRedraw : boolean)
Inserts a new property into an existing record with jsxid equal to strRecordId. If the property already exists, the existing property value will be updated. If no such record exists in the XML document, this method fails quietly.

Parameters:

strRecordIdthe jsxid attribute of the data record to modify.
strPropNamethe name of the property to insert into the record.
strPropValuethe value of the property to insert.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the inserted property.

Returns:

this object.  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


paintChild

void paintChild(objJSX : jsx3.app.Model, bGroup : ?)
inserts DHTML (as string) into IE's on-screen DOM as a child of the object's on-screen VIEW

Parameters:

objJSXdirect child whose generated VIEW will be directly inserted into the DOM to provide more efficient screen updates as repaint is costly for large applications
bGroup

Overrides:


redrawCell

void redrawCell(strRecordId : String, objColumn : jsx3.gui.Matrix.Column, bSuppressTriggers : boolean, objTRXML : jsx3.xml.Entity)
Updates the on-screen cell to reflect the value in the CDF document to which the cell is mapped.

Parameters:

strRecordIdjsxid value for the record node (according to the CDF) corresponding to the on-screen row to update
objColumnColumn instance to update. Any sibling Columns that map to the same named attribute as objColumn (e.g., [objColumn].getPath()) as well as all sibling Columns that are triggered by the named attribute (e.g., [objColumn].getTriggers()) will also be redrawn.
bSuppressTriggersif true, no other sibling Columns will be updated, even if they share a common path or designate the path as one of their triggers.
objTRXMLif present, use instead of generating the row XHTML via XSLT

See Also:

,

redrawMappedCells

void redrawMappedCells(strRecordId : String, strAttName : String)
Updates the on-screen cell to reflect the value in the CDF document to which the cell is mapped.

Parameters:

strRecordIdThe jsxid value for the record node (according to the CDF) corresponding to the on-screen row to update
strAttNameNamed attribute on the CDF record. All Column children that map to this named attribute (e.g., [objColumn].getPath()) as well as all Column children that are triggered by the named attribute (e.g., [objColumn].getTriggers()) will be redrawn.

See Also:

,

redrawRecord

void redrawRecord(strRecordId : String, intAction : int, bRecurse : boolean)
Matrix implementation.

Parameters:

strRecordIdjsxid value for the record node (according to the CDF) to redraw
intActionjsx3.xml.CDF.INSERT, jsx3.xml.CDF.INSERTBEFORE, jsx3.xml.CDF.DELETE, or jsx3.xml.CDF.UPDATE.
bRecurseif != false, any necessary recursion for flattened inserts will be automatically handled

Overrides:


repaint

String repaint()
Updates the view of this object by calling paint() and replacing the current view with the returned HTML. This method has no effect if this object is not currently displayed.

Returns:

the result of calling paint() or null if this object is not displayed. 

Overrides:

See Also:


repaintData

void repaintData()
Paints only the data rows. Call for quick repainting of the data rows when only the source data has changed. Does not recalculate and reprofile the box profile and resulting XSLT. Retains scroll position when possible.

repaintHead

void repaintHead()
Repaints the header row for improved runtime efficiency. For example, a minor text change to a label in a header row shouldn't repaint the entirety of the instance

resetCacheData

void resetCacheData(objServer : jsx3.app.Server)
Removes the XML source document stored under the XML ID of this object from the server cache.

Parameters:

objServerthe server owning the cache to modify. This is a required argument only if this.getServer() does not returns a server instance.

Overrides:


resetFocusContext

void resetFocusContext(strId : ?)
Removes the focus style from whichever cell is designated to have focus context. Once focus context is applied to the active cell in a matrix, the focus style will continue to be applied to the active cell until another cell is set as the active cell or the Matrix is repainted via a call to repaint or repaintData.

Parameters:

strId

resetMask

void resetMask()
Ends any existing edit session and hides the active mask. This is a carryover method from grid.

resetXmlCacheData

void resetXmlCacheData(objServer : jsx3.app.Server)
Removes the XML source document stored under the XML ID of this object from the server cache.

Parameters:

objServerthe server owning the cache to modify. This is a required argument only if this.getServer() does not returns a server instance.

Overrides:


revealRecord

void revealRecord(strRecordId : String)
Reveals a record by toggling parent nodes open (if rendering hierarcally) and scrolling the record into view.

Parameters:

strRecordIdthe id of the record to reveal

selectRecord

void selectRecord(strRecordId : String)
Selects a CDF record of this list. The item will be highlighted in the view and the CDF data will be updated accordingly. If this list is a multi-select list then this selection will be added to any previous selection.

Parameters:

strRecordIdthe jsxid of the record to select.

setAutoRow

void setAutoRow(intBoolean : int)
Sets whether or not an 'auto append' row will be rendered, allowing the user to automatically add new rows to the instance. Note that if the rendering model is hierarchical or the paging model is jsx3.gui.Matrix.PAGING_PAGED, the auto row feature is disabled. The CSS style for the auto row (a TR element) can be modified via the XSL Parameters palette, via the XSL parameter, jsx_autorow_style

Parameters:

intBooleanjsx3.Boolean.TRUE if the column widths should be adjusted to fully fit within the viewport

setBodyBorder

jsx3.gui.Block setBodyBorder(strCSS : String, bSuppressRepaint : boolean)
Sets CSS property value(s) for a border (border: solid 1px #000000). Updates MODEL and VIEW (unless repaint is suppressed).

Parameters:

strCSSvalid CSS property value for a border (border: solid 1px #000000)
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as borders) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

Returns:

this object  

setCanReorder

void setCanReorder(REORDER : int)
Sets whether the columns in the list can be re-ordered via user interaction with the VIEW

Parameters:

REORDERone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setCanSort

void setCanSort(SORT : int)
Sets whether the list will render with sortable columns.

Parameters:

SORTone of jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setFixedColumnIndex

void setFixedColumnIndex(intIndex : int)
Sets the zero-based index of the on-screen column(s), to the left of which will be fixed and cannot be reordered.

Parameters:

intIndexpositive integer

setFocusStyle

void setFocusStyle(strCSS : String)
Sets the CSS string to apply to a Row/Cell when it has focus. NOTE: Passing styles that affect position, left, top, width, height, border, background-image, padding, and margin (those reserved by the class) can have undesired effects.

Parameters:

strCSSValid CSS. For example: font-weight:bold;color:orange;

setHeaderBorder

void setHeaderBorder(strCSS : String)
Sets CSS property value(s) for a border on the header row (border: solid 1px #000000). Updates both model and view.

Parameters:

strCSSvalid CSS property value for a border (border: solid 1px #000000)

setHeaderHeight

void setHeaderHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the height of the header row in pixels. Set to zero (0) to hide the header row and only render the body rows.

Parameters:

intHeight
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as height) are repainted immediately to keep the box model abstraction in sync with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setIcon

void setIcon(strURL : String)
Sets the icon to use for those CDF records that do not explicitly specify an icon via the jsximg attribute

Parameters:

strURLURL for icon to use

setIconMinus

void setIconMinus(strURL : String)
Sets the icon to use when the given tree node is in an open state.

Parameters:

strURLURL (preferably relative)

setIconPlus

void setIconPlus(strURL : String)
Sets the icon to use when the given tree node is in a closed state.

Parameters:

strURLURL (preferably relative)

setPagingModel

void setPagingModel(intModel : int)
Sets how data should be painted on-screen. If no value is specified, jsx3.gui.Matrix.PAGING_OFF will be applied.

Parameters:

intModelone of: Matrix. PAGING_OFF, PAGING_2PASS, PAGING_CHUNKED, PAGING_PAGED, PAGING_STEPPED

setPanelPoolSize

void setPanelPoolSize(intCount : int)
Sets the number panels (a panel contains a collection of rows--getRowsPerPanel()) that should be part of the pool.

Parameters:

intCount

setPanelQueueSize

void setPanelQueueSize(intCount : int)
Sets the number of panels that are allowed in the queue waiting to be painted. Can be tuned up or down to optimize performance given the amount of data, connection speed, etc

Parameters:

intCount

setReaperInterval

void setReaperInterval(intInterval : int)
Sets the the number of milliseconds to wait before checking for inactive panels to garbage collect.

Parameters:

intIntervalnumber of milliseconds

setRenderNavigators

void setRenderNavigators(intTrueFalse : int, bSuppressRepaint : boolean)
Sets whether or not to render the navigation controls on the first column when being rendered in hierarchical mode.

Parameters:

intTrueFalsejsx3.Boolean.TRUE or jsx3.Boolean.FALSE
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as rendering the navigational controls) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setRenderingContext

void setRenderingContext(strJsxId : String, bSuppressRepaint : boolean)
Sets the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.

Parameters:

strJsxIdjsxid property for the CDF record to use as the contextual root when rendering data on-screen.
bSuppressRepaintPass true to stop the default repaint from occurring.

setRenderingModel

void setRenderingModel(MODEL : String, bSuppressRepaint : boolean)
Sets the rendering model (how rows will be painted on-screen).

Parameters:

MODELone of: shallow, deep, or hierarchical
bSuppressRepaintPass true to stop the default repaint from occurring.

setResizable

void setResizable(RESIZE : int)
Sets whether or not this column can be resized by the user. If not set, the column will be assumed resizable. Note that if the parent Matrix is set as NOT resizable, this setting is ignored and no child columns can be resized

Parameters:

RESIZE

setRowHeight

void setRowHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the on-screen row height. If row height is null, the default row height will be used (jsx3.gui.Matrix.DEFAULT_ROW_HEIGHT). If row height is 0, the row height is flexible and the row's height will expand to fit the content.

Parameters:

intHeightheight in pixels
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as padding) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setRowsPerPanel

void setRowsPerPanel(intCount : int, bSuppressRepaint : boolean)
Sets the number of rows each panel should contain.

Parameters:

intCount
bSuppressRepaintPass true to stop the default repaint from occurring.

setScaleWidth

void setScaleWidth(intBoolean : int)
Sets whether or not the column widths should be adjusted such that all columns visually display within the viewport. Defaults to jsx3.Boolean.FALSE if not set, meaning a horizontal scrollbar will appear if the aggregate column widths exceed the available width of the viewport.

Parameters:

intBooleanOne of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setScrollInfoLabel

void setScrollInfoLabel(strLabel : String)
Sets the standard info label to display when scrolling to show the scroll position. If no label is supplied an appropriate localized value will be used. Set to an empty string to suppress any label from displaying.

Parameters:

strLabelvalid HTML/Text. Set to an empty string to suppress any label from displaying.
Wildcards are as follows:
  • {0} The index position of the first visible on-screen row
  • {1} The index position of the last visible on-screen row
  • {2} Total count of all records in the list

setScrollLeft

void setScrollLeft(intScrollLeft : int)
Sets the horizontal scroll position.

Parameters:

intScrollLefta non-negative number

setScrollTop

void setScrollTop(intScrollTop : int, objGUI : HTMLElement)
Sets the vertical scroll position.

Parameters:

intScrollTopa non-negative number
objGUI

setSelectionBG

void setSelectionBG(strURL : String)
Sets the URL for the image to use (as the repeating background image) to denote selection.

Parameters:

strURL

setSelectionModel

void setSelectionModel(intType : int)
Sets the selection model

Parameters:

intTypeone of: jsx3.gui.Matrix.SELECTION_UNSELECTABLE, jsx3.gui.Matrix.SELECTION_ROW, jsx3.gui.Matrix.SELECTION_MULTI_ROW

setSortDirection

void setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.

Parameters:

intSortDirone of: jsx3.gui.Matrix.SORT_ASCENDING or jsx3.gui.Matrix.SORT_DESCENDING

setSortPath

void setSortPath(strAttr : String)
Sets the name of the CDF attribute to sort on. The records in the data source of this matrix are sorted on this attribute before being painted to screen.

Parameters:

strAttr

See Also:


setSortType

void setSortType(DATATYPE : String)
Sets the data type for the list. This explicit value will override any column data type if set. If it is not set the data type specific to the sort column is used for sorting.

Parameters:

DATATYPEdata type for this column's data; ; valid types include: jsx3.gui.Matrix.Column.TYPE_TEXT and jsx3.gui.Matrix.Column.TYPE_NUMBER

setSuppressHScroller

void setSuppressHScroller(intTrueFalse : int)
Sets whether or not to supress display of the horizontal scrollbar. Updates both model and view

Parameters:

intTrueFalsejsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setSuppressVScroller

void setSuppressVScroller(intTrueFalse : int, bSuppressRepaint : boolean)
Sets whether or not to supress display of the vertical scrollbar. Updates both model and view.

Parameters:

intTrueFalsejsx3.Boolean.TRUE or jsx3.Boolean.FALSE
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as rendering the vertical scrollbar) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setValue

jsx3.gui.Matrix setValue(strId : String | Array<String>)
Sets the value of this matrix. Deselects all existing selections. Scrolls the first record into view.

Parameters:

strIdjsxid attribute for the CDF record(s) to select

Returns:

this object.  

Overrides:


setXMLId

jsx3.xml.Cacheable setXMLId(strXMLId : String)
Sets the XML ID of this object. This value is the key under which the XML source document of this object is saved in the cache of the server owning this object. The developer may specify either a unique or shared value. If no value is specified, a unique id is generated.

Parameters:

strXMLId

Returns:

this object. 

Overrides:

See Also:


setXMLString

jsx3.xml.Cacheable setXMLString(strXML : String)
Sets the XML string of this object. Setting this value to the string serialization of an XML document is one way of specifying the source XML document of this object.

Parameters:

strXMLnull or a well-formed serialized XML element.

Returns:

this object. 

Overrides:

See Also:


setXMLURL

jsx3.xml.Cacheable setXMLURL(strXMLURL : String)
Sets the XML URL of this object. Settings this value to the URI of an XML document is one way of specifying the source XML document of this object.

Parameters:

strXMLURLnull or a URI that when resolved against the server owning this object specifies a valid XML document.

Returns:

this object. 

Overrides:

See Also:


synchronizeVScroller

void synchronizeVScroller()
Updates the scroll height and scroll position of the vertical scrollbar. When a Matrix instance has a display property of none (or is contained by an ancestor with a display of none) and the Matrix is repainted (repaint/repaintData), the browser will misreport how large the content actually is. When the Matrix is then restored the scrollbars will be disabled. By calling this method after the view has been restored (i.e., when display is set to block), the scrollbars will reflect the accurate height.

toggleItem

void toggleItem(strRecordId : String, bOpen : boolean)
Toggles the open/closed state for a node in the Matrix

Parameters:

strRecordIdthe 'jsxid' attribute on the given CDF record to toggle
bOpenif null, the open state will be toggled

jsx3.gui

interface Matrix.BlockMask

jsx3.gui.Matrix.EditMask
->jsx3.gui.Matrix.BlockMask

interface Matrix.BlockMask
extends jsx3.gui.Matrix.EditMask
The interface that defines the methods that affect the behavior of a composite object used as an edit mask of a matrix column. Any object used as an edit mask that extends jsx3.gui.Block but does not implement jsx3.gui.Form will have these methods inserted into it. Such an object only has to define the methods whose default behavior it wishes to override.

Since:

3.2

Method Summary
void
emBeginEdit(strValue : ?, objTdDim : ?, objPaneDim : ?, objMatrix : ?, objColumn : ?, strRecordId : ?, objTD : ?)
void
void
void
emInit(objColumn : ?)
jsx3.gui.Painted
Returns the DOM node that should be focused when the edit session begins.
String
Returns the value currently stored in this edit mask.
void
setMaskValue(strValue : String)
Sets the value currently stored in this edit mask.
Methods Inherited From jsx3.gui.Matrix.EditMask
commitEditMask, emGetSession, resumeEditSession, suspendEditSession
Method Detail

emBeginEdit

final void emBeginEdit(strValue : ?, objTdDim : ?, objPaneDim : ?, objMatrix : ?, objColumn : ?, strRecordId : ?, objTD : ?)

Parameters:

strValue
objTdDim
objPaneDim
objMatrix
objColumn
strRecordId
objTD

Overrides:


emEndEdit

final void emEndEdit()

Overrides:


emGetValue

final void emGetValue()

Overrides:


emInit

final void emInit(objColumn : ?)

Parameters:

objColumn

Overrides:


getMaskFirstResponder

jsx3.gui.Painted getMaskFirstResponder()
Returns the DOM node that should be focused when the edit session begins. The default behavior is to return the first descendant (breadth-first) that implements jsx3.gui.Form.

Returns:

 

getMaskValue

String getMaskValue()
Returns the value currently stored in this edit mask. The default behavior is to return the value of the first descendant (breadth-first) that implements jsx3.gui.Form.

Returns:

 

setMaskValue

void setMaskValue(strValue : String)
Sets the value currently stored in this edit mask. The default behavior is to set the value of the first descendant (breadth-first) that implements jsx3.gui.Form.

Parameters:

strValue

jsx3.gui

class Matrix.Column

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Matrix.Column

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Matrix.Column
extends jsx3.gui.Block
Column control for use as a child of a jsx3.gui.Matrix class

Since:

3.2

Field Summary
static String
top
static int
100
static String
number
static String
text (default)
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
jsx3.Boolean
Returns whether the parent list/grid can be sorted on this column.
String
Returns CSS property value for the data cell background-color.
String
Returns CSS property value for the data cell border.
String
Returns CSS property value for the data cell color.
String
Returns CSS property value for the data cell cursor.
String
Returns the CSS property value for the data cell font-family.
int
Returns the CSS property value for the data cell font-size.
String
Returns the CSS property value for the data cell font-weight.
String
Returns the CSS property value for the data cell padding.
String
Returns the CSS property value for the data cell text-align.
String
Returns the CSS property value for the data cell vertical-align.
int
getCellWrap(strDefault : String)
Returns whether or not the data cellc will support text-wrapping.
String
Returns the data type for this column of data (affects sorting if this column is used for sorting the data); valid types include: jsx3.gui.Matrix.Column.TYPE_TEXT and jsx3.gui.Matrix.Column.TYPE_NUMBER
int
Returns the zero-based index for ths column in relation to its siblings.
String
Gets the named object that will handle the reformatting of a given column's data cells.
String
Returns the selection path for this column of data.
jsx3.Boolean
Gets whether or not this column can be resized by the user.
String
Returns the data type for this column of data (affects sorting if this column is used for sorting the data).
String
Returns the CDF attribute to use to sort on this column.
String
Returns one or more named attributes.
String
Returns the CSS property value for the header cell vertical-align.
String
getValueTemplate(strDefault : String)
Gets the user-defined XSL template (xsl:template) that will override the defualt template defined by Column.TEMPLATES.default.
jsx3.Boolean
getWrap(strDefault : String)
Gets whether or not the header cell will support text-wrapping.
String
Returns the DHTML, used for this object's on-screen VIEW
String
Updates the view of this object by calling paint() and replacing the current view with the returned HTML.
void
setBorder(strCSS : String)
Sets property value(s) for a border for the header cell (solid 1px #000000).
void
Sets whether the parnet list/grid can be sorted on this column.
void
Sets CSS property value for the data cell background-color.
void
setCellBorder(strCSS : String, bSuppressRepaint : boolean)
Sets CSS property value(s) for a border for the data cells.
void
setCellColor(strColor : String)
Sets CSS property value for the data cell color.
void
setCellCursor(strCursor : String)
Sets CSS property value for the data cell cursor.
void
setCellFontName(strFontName : String)
Sets the CSS property value for the data cell font-family.
void
setCellFontSize(intPixelSize : int)
Sets the CSS property value for the data cell font-size.
void
setCellFontWeight(FONTWEIGHT : String)
Sets the CSS property value for the data cell font-weight.
void
setCellPadding(strCSS : String, bSuppressRepaint : boolean)
Sets the CSS property value for the data cell padding.
void
Sets the CSS property value for the data cell text-align.
void
setCellVAlign(VALIGN : String)
Sets the CSS property value for the data cell vertical-align.
void
setCellWrap(WRAP : int)
Sets whether or not the data cellc will support text-wrapping.
void
setDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self
jsx3.gui.Matrix.Column
setDisplay(DISPLAY : String, bRepaint : boolean)
Sets the display for the object.
void
Sets the identifier for which of the default column formatters should be implemented.
void
setPadding(strCSS : String)
Sets CSS property value(s) for a padding for the header cell.
void
setPath(strPath : String, bSuppressRepaint : boolean)
Sets the selection path for this column of data.
void
Sets whether or not this column can be resized by the user.
void
setSortDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self
void
setSortPath(strPath : String)
Sets the CDF attribute to use to sort on this column.
jsx3.gui.Matrix.Column
setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen.
void
setTriggers(strTriggers : String)
Sets one or more named attributes.
void
setVAlign(VALIGN : String)
Sets the CSS property value for the header cell vertical-align.
void
setValueTemplate(TEMPLATE : String)
Sets the user-defined XSL template (xsl:template) that will override the defualt template defined by Column.DEFAULT_VALUE_TEMPLATE.
jsx3.gui.Matrix.Column
setWidth(vntWidth : String | int, bRepaint : boolean)
Sets the Width on the column.
void
Sets whether or not the header cell will support text-wrapping.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setRelativePosition, setTagName, setTextAlign, setTip, setTop, setVisibility, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULT_VALIGN

static final String DEFAULT_VALIGN
top

DEFAULT_WIDTH

static int DEFAULT_WIDTH
100

TYPE_NUMBER

static final String TYPE_NUMBER
number

TYPE_TEXT

static final String TYPE_TEXT
text (default)
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

getCanSort

jsx3.Boolean getCanSort()
Returns whether the parent list/grid can be sorted on this column. If no value is provided, the column is assumed sortable unless the parent control explicitly specifies that no column should sort.

Returns:

 

See Also:


getCellBackgroundColor

String getCellBackgroundColor()
Returns CSS property value for the data cell background-color.

Returns:

 

getCellBorder

String getCellBorder()
Returns CSS property value for the data cell border.

Returns:

 

getCellColor

String getCellColor()
Returns CSS property value for the data cell color.

Returns:

 

getCellCursor

String getCellCursor()
Returns CSS property value for the data cell cursor.

Returns:

 

getCellFontName

String getCellFontName()
Returns the CSS property value for the data cell font-family.

Returns:

 

getCellFontSize

int getCellFontSize()
Returns the CSS property value for the data cell font-size.

Returns:

 

getCellFontWeight

String getCellFontWeight()
Returns the CSS property value for the data cell font-weight.

Returns:

 

getCellPadding

String getCellPadding()
Returns the CSS property value for the data cell padding.

Returns:

 

getCellTextAlign

String getCellTextAlign()
Returns the CSS property value for the data cell text-align.

Returns:

 

getCellVAlign

String getCellVAlign()
Returns the CSS property value for the data cell vertical-align. If no value is provided, the data cells render top-aligned.

Returns:

 

getCellWrap

int getCellWrap(strDefault : String)
Returns whether or not the data cellc will support text-wrapping. If no value is specified, the text will not wrap

Parameters:

strDefaultThe default value to use if null

Returns:

 

getDataType

String getDataType()
Returns the data type for this column of data (affects sorting if this column is used for sorting the data); valid types include: jsx3.gui.Matrix.Column.TYPE_TEXT and jsx3.gui.Matrix.Column.TYPE_NUMBER

Returns:

data type for this column's data  

getDisplayIndex

int getDisplayIndex()
Returns the zero-based index for ths column in relation to its siblings. This is different from getChildIndex in that it corresponds to the position of this column as rendered on-screen, meaning if a child of a lesser index is not displayed (e.g., display = none), the value returned from this method will be less than what would be returned by getChildIndex. Returns null if this object is not displayed.

Returns:

 

See Also:


getFormatHandler

String getFormatHandler()
Gets the named object that will handle the reformatting of a given column's data cells. This object should implment the interface, jsx3.gui.Matrix.ColumnFormat, or adhere to its APIs. Can also return the function literal

Returns:

named object or function literal 

See Also:


getPath

String getPath()
Returns the selection path for this column of data. Returns 'jsxid' if no path specified

Returns:

selection path  

getResizable

jsx3.Boolean getResizable()
Gets whether or not this column can be resized by the user. If not set, the column will be assumed resizable

Returns:

 

getSortDataType

String getSortDataType()
Returns the data type for this column of data (affects sorting if this column is used for sorting the data).

Returns:

one of: jsx3.gui.Matrix.Column.TYPE_TEXT, jsx3.gui.Matrix.Column.TYPE_NUMBER  

getSortPath

String getSortPath()
Returns the CDF attribute to use to sort on this column. If the sort path has not been set explicitly, this method returns the value of this.getPath(). The data source of the matrix containing this column is sorted on this attribute when the matrix is sorted on this column.

Returns:

 

See Also:


getTriggers

String getTriggers()
Returns one or more named attributes. When one of these attributes is updated by another column's edit mask iterface, this column will called to repaint to reflect the updated value

Returns:

Comma-delimited attribute list  

getVAlign

String getVAlign()
Returns the CSS property value for the header cell vertical-align. If no value is provided, the header cell render top-aligned.

Returns:

 

getValueTemplate

String getValueTemplate(strDefault : String)
Gets the user-defined XSL template (xsl:template) that will override the defualt template defined by Column.TEMPLATES.default.

Parameters:

strDefaultxsl:template

Returns:

 

getWrap

jsx3.Boolean getWrap(strDefault : String)
Gets whether or not the header cell will support text-wrapping. If not specified, the cell will be painted with no wrapping.

Parameters:

strDefaultThe default value to use if null

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


repaint

String repaint()
Updates the view of this object by calling paint() and replacing the current view with the returned HTML. This method has no effect if this object is not currently displayed.

Returns:

the result of calling paint() or null if this object is not displayed. 

Overrides:

See Also:


setBorder

void setBorder(strCSS : String)
Sets property value(s) for a border for the header cell (solid 1px #000000). Updates are applied immediately

Parameters:

strCSSvalid CSS property value for a border (border: solid 1px #000000) or GI shorthand notation for border

Overrides:


setCanSort

void setCanSort(SORT : jsx3.Boolean)
Sets whether the parnet list/grid can be sorted on this column. Note that the header row is immediately repainted to reflect the change.

Parameters:

SORT

setCellBackgroundColor

void setCellBackgroundColor(strColor : String)
Sets CSS property value for the data cell background-color. Call repaint on the parent instance to update the view.

Parameters:

strColorvalid CSS property value, (e.g., red, #ff0000, rgb(255,0,0))

setCellBorder

void setCellBorder(strCSS : String, bSuppressRepaint : boolean)
Sets CSS property value(s) for a border for the data cells. Updates MODEL and VIEW (unless repaint is suppressed).

Parameters:

strCSSvalid CSS property value for border. For example: solid 1px red;solid 0px;solid 0px;solid 1px white
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as borders) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setCellColor

void setCellColor(strColor : String)
Sets CSS property value for the data cell color. Call repaint on the parent instance to update the view.

Parameters:

strColorvalid CSS property value, (e.g., red, #ffffff, rgb(255,0,0))

setCellCursor

void setCellCursor(strCursor : String)
Sets CSS property value for the data cell cursor. Call repaint on the parent instance to update the view.

Parameters:

strCursorCSS property value, (e.g., default, wait, col-resize)

setCellFontName

void setCellFontName(strFontName : String)
Sets the CSS property value for the data cell font-family. Call repaint on the parent instance to update the view.

Parameters:

strFontNamevalid CSS font-family property value (e.g., Arial, Courier)

setCellFontSize

void setCellFontSize(intPixelSize : int)
Sets the CSS property value for the data cell font-size. Call repaint on the parent instance to update the view.

Parameters:

intPixelSizefont-size (in pixels)

setCellFontWeight

void setCellFontWeight(FONTWEIGHT : String)
Sets the CSS property value for the data cell font-weight. Call repaint on the parent instance to update the view.

Parameters:

FONTWEIGHTone of: jsx3.gui.Block.FONTBOLD, jsx3.gui.Block.FONTNORMAL

setCellPadding

void setCellPadding(strCSS : String, bSuppressRepaint : boolean)
Sets the CSS property value for the data cell padding. Updates MODEL and VIEW (unless repaint is suppressed).

Parameters:

strCSSvalid CSS property value for padding. For example: 8 4 8 4
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as padding) are repainted immediately to keep the box model abstraction in synch with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setCellTextAlign

void setCellTextAlign(ALIGN : String)
Sets the CSS property value for the data cell text-align. Call repaint on the parent instance to update the view.

Parameters:

ALIGNone of: jsx3.gui.Block.ALIGNLEFT, jsx3.gui.Block.ALIGNRIGHT, jsx3.gui.Block.ALIGNCENTER

setCellVAlign

void setCellVAlign(VALIGN : String)
Sets the CSS property value for the data cell vertical-align. Call repaint on the parent instance to update the view.

Parameters:

VALIGNvalid CSS value for vertical-align style.

setCellWrap

void setCellWrap(WRAP : int)
Sets whether or not the data cellc will support text-wrapping. If no value is specified, the text will not wrap. Call repaint to update the VIEW

Parameters:

WRAPjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setDataType

void setDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self

Parameters:

DATATYPEone of: jsx3.gui.Matrix.Column.TYPE_TEXT, jsx3.gui.Matrix.Column.TYPE_NUMBER

setDisplay

jsx3.gui.Matrix.Column setDisplay(DISPLAY : String, bRepaint : boolean)
Sets the display for the object. Note that although the framework uses CSS to apply this setting, the actual values that get set are determined by the system. Only those values listed for the parameter, DISPLAY, are supported as inputs to this function. Calling this method will cause the underlying XSLT for the Matrix parent to be regenerated.

Parameters:

DISPLAYone of jsx3.gui.Block.DISPLAYNONE and jsx3.gui.Block.DISPLAYBLOCK
bRepaintif true, the view of this object is immediately updated.

Returns:

this object  

Overrides:


setFormatHandler

void setFormatHandler(handler : String | Function | jsx3.gui.Matrix.ColumnFormat)
Sets the identifier for which of the default column formatters should be implemented. A function literal can also be passed.

Parameters:

handlerincluding @unescape, @lookup, @message, @datetime, @date, @time, and @number. For example: @unescape.

- or -

Function literal with the signature, function(element,cdfkey, matrix, column, rownumber,server). For example:

function(element, cdfkey, matrix, column, rownumber, server) {
  var mf = new jsx3.util.MessageFormat("{0,number,currency}");
  element.innerHTML = mf.format(element.innerHTML);
};

See Also:


setPadding

void setPadding(strCSS : String)
Sets CSS property value(s) for a padding for the header cell. Updates are applied immediately.

Parameters:

strCSSvalid CSS property value for padding. For example: 8 4 8 4

Overrides:


setPath

void setPath(strPath : String, bSuppressRepaint : boolean)
Sets the selection path for this column of data.

Parameters:

strPathThe name of the attribute For example jsxtext
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the XSLT (such as path) require that the XSLT be regenerated. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setResizable

void setResizable(RESIZE : jsx3.Boolean)
Sets whether or not this column can be resized by the user. If not set, the column will be assumed resizable. Note that if the parent Matrix is set as NOT resizable, this setting is ignored and no child columns can be resized. Note that the header row is immediately repainted to reflect the change.

Parameters:

RESIZE

setSortDataType

void setSortDataType(DATATYPE : String)
Sets the data type for this column of data (affects sorting if this column is used for sorting the data); returns ref to self

Parameters:

DATATYPEdata type for this column's data. valid types include: jsx3.gui.Matrix.Column.TYPE_TEXT and jsx3.gui.Matrix.Column.TYPE_NUMBER

setSortPath

void setSortPath(strPath : String)
Sets the CDF attribute to use to sort on this column.

Parameters:

strPath

setText

jsx3.gui.Matrix.Column setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen.

Parameters:

strTexttext/HTML
bRepaintif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

 

Overrides:


setTriggers

void setTriggers(strTriggers : String)
Sets one or more named attributes. When one of these attributes is updated by another column's edit mask iterface, this column will called to repaint to reflect the updated value

Parameters:

strTriggersComma-delimited attribute list. For example: jsxtext, ssn, phone.

setVAlign

void setVAlign(VALIGN : String)
Sets the CSS property value for the header cell vertical-align. Repaints the header to immediately reflect this change.

Parameters:

VALIGNvalid CSS value for vertical-align style.

setValueTemplate

void setValueTemplate(TEMPLATE : String)
Sets the user-defined XSL template (xsl:template) that will override the defualt template defined by Column.DEFAULT_VALUE_TEMPLATE.
The path wildcard is as follows:
  • {0} this will be replaced with the result of [instance].getPath(). For example: jsxtext

Parameters:

TEMPLATEEither a valid xsl:template or a named system template, including: @default, @empty, @unescape, and @image

setWidth

jsx3.gui.Matrix.Column setWidth(vntWidth : String | int, bRepaint : boolean)
Sets the Width on the column. Immediately updates MODEL and VIEW. Note that if a wilcard is used without Scale Width, it will be replaced with the value of jsx3.gui.Matrix.Column.DEFAULT_WIDTH

Parameters:

vntWidthCan be a valid number (pixel units are implied), a Percent, or a Wildcard. For example: 100, 25%, *
bRepaintalways treated as true.

Returns:

 

Overrides:

See Also:


setWrap

void setWrap(WRAP : jsx3.Boolean)
Sets whether or not the header cell will support text-wrapping. Repaints the header to immediately reflect this change.

Parameters:

WRAP

jsx3.gui

class Matrix.ColumnFormat

Object
->jsx3.lang.Object
  ->jsx3.gui.Matrix.ColumnFormat

abstract class Matrix.ColumnFormat
extends jsx3.lang.Object
A class that defines the methods required for an object to be used by jsx3.gui.Matrix.Column instances to format cells of data.

Since:

3.2

Method Summary
abstract void
format(objDiv : HTMLElement, strCDFKey : String, objMatrix : jsx3.gui.Matrix, objMatrixColumn : jsx3.gui.Matrix.Column, intRowNumber : int, objServer : jsx3.app.Server)
Formats the Matrix cell, a native DIV element.
static jsx3.gui.Matrix.ColumnFormat
getInstance(strKey : String, objColumn : jsx3.gui.Matrix.Column)
Returns a column formatter for a string key.
boolean
Classes that implement this interface must provide this method to allow for browser-specific or similar type 'switch'.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

format

abstract void format(objDiv : HTMLElement, strCDFKey : String, objMatrix : jsx3.gui.Matrix, objMatrixColumn : jsx3.gui.Matrix.Column, intRowNumber : int, objServer : jsx3.app.Server)
Formats the Matrix cell, a native DIV element.

Parameters:

objDivon-screen DIV element to be formatted. Note that this DIV is contained within a TD
strCDFKeyCDF record id for the record in the data model bound to the affected on-screen row
objMatrixmatrix instance
objMatrixColumnmatrix column instance
intRowNumberrow number for row containing this cell (1-based)
objServerserver instance. Useful for querying locale (for localized output)

getInstance

static jsx3.gui.Matrix.ColumnFormat getInstance(strKey : String, objColumn : jsx3.gui.Matrix.Column)
Returns a column formatter for a string key. The key may be one of the following:
  • @unescape
  • @unescape_all
  • @lookup
  • @datetime[,(short|medium|long|full,format)]
  • @date[,(short|medium|long|full,format)]
  • @time[,(short|medium|long|full,format)]
  • @number[,(integer|percent|currency,format)]
  • @message,format

Parameters:

strKey
objColumn

Returns:

 

validate

boolean validate()
Classes that implement this interface must provide this method to allow for browser-specific or similar type 'switch'. If false is returned, the formatter will not even attempt to iterate

Returns:

true if the formatter should be called to iterate and format  

jsx3.gui

interface Matrix.EditMask

jsx3.gui.Matrix.EditMask

interface Matrix.EditMask
The interface defining the methods that affect the behavior of an object used as an edit mask in a matrix column.

If an object is placed in the DOM as a child of a matrix column, it will be used as an edit mask. Any methods in this interface that the object does not implement will be inserted into the object. This interface is a "loose" interface because the class of an edit mask does not need to implement it in its class declaration. The class simply needs to define any methods whose default behavior it wishes to override.

Any edit mask that implements the jsx3.gui.Form interface will have the methods in this interface inserted into it. If the edit mask does not implement jsx3.gui.Form but extends jsx3.gui.Block, the methods in the jsx3.gui.Matrix.BlockMask interface are inserted instead.

Since:

3.2

See Also:

jsx3.gui.Matrix.BlockMask

Method Summary
void
commitEditMask(objEvent : jsx3.gui.Event, bKeepOpen : boolean)
Commits the current edit session of this edit mask.
boolean
emBeginEdit(strValue : String, objTdDim : Object<String, int>, objPaneDim : Object<String, int>, objMatrix : jsx3.gui.Matrix, objColumn : jsx3.gui.Matrix.Column, strRecordId : String, objTD : HTMLElement)
Called whenever an edit session begins.
String
Called when the current edit session ends.
Object<String, Object>
Returns the state of the current edit session if this object is involved in a jsx3.gui.Matrix edit mask session.
String
Returns the current value stored in the edit mask.
void
This method is called once when the edit mask is discovered by the matrix column to give it an opportunity to initialize itself.
void
Resumes an edit session so that the edit session will close the next time this mask loses focus.
void
Suspends an edit session so that if this mask loses focus, the edit session does not close.
Method Detail

commitEditMask

void commitEditMask(objEvent : jsx3.gui.Event, bKeepOpen : boolean)
Commits the current edit session of this edit mask.

Parameters:

objEventthe wrapped browser event that logically caused this commit to occur. If this parameter is provided then all the model events related to committing an edit session are triggered.
bKeepOpenif true then the current value of this edit mask is committed without closing the current edit session.

emBeginEdit

boolean emBeginEdit(strValue : String, objTdDim : Object<String, int>, objPaneDim : Object<String, int>, objMatrix : jsx3.gui.Matrix, objColumn : jsx3.gui.Matrix.Column, strRecordId : String, objTD : HTMLElement)
Called whenever an edit session begins.

Parameters:

strValue
objTdDim
objPaneDim
objMatrix
objColumn
strRecordId
objTD

Returns:

false to cancel the edit session.  

emEndEdit

String emEndEdit()
Called when the current edit session ends. This method should return the edited value.

Returns:

the edited value.  

emGetSession

final Object<String, Object> emGetSession()
Returns the state of the current edit session if this object is involved in a jsx3.gui.Matrix edit mask session. The state has the following keys:
  • matrix {jsx3.gui.Matrix}
  • column {jsx3.gui.Matrix.Column}
  • recordId {String}
  • td {HTMLElement}
  • value {String} may be null

Returns:

the edit session. 

emGetValue

String emGetValue()
Returns the current value stored in the edit mask.

Returns:

the current value of the edit mask.  

emInit

void emInit(objColumn : jsx3.gui.Matrix.Column)
This method is called once when the edit mask is discovered by the matrix column to give it an opportunity to initialize itself.

Parameters:

objColumnthe matrix column parent.

resumeEditSession

final void resumeEditSession()
Resumes an edit session so that the edit session will close the next time this mask loses focus.

suspendEditSession

final void suspendEditSession()
Suspends an edit session so that if this mask loses focus, the edit session does not close.

jsx3.gui

class Menu

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Menu

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Menu
extends jsx3.gui.Block
Create GUI menus, similar in functionality to system menus (File, Edit, etc) created by the host OS.

This class implements the CDF interface. Each record represents an item in the rendered menu. The following CDF attributes are supported by default:

Field Summary
static String
background-image:url(JSX/images/menu/bg.gif);backround-repeat:repeat-y; (default)
static String
#ffffff (default)
static int
static String
Deprecated.
static String
static String
Deprecated.
Constructor Summary
void
init(strName : String, strText : String)
The instance initializer.
Method Summary
void
Deprecated. No-op.
jsx3.gui.Menu
deselectItem(strRecordId : String)
flags a a menu item as being unselected (the default state)
jsx3.gui.Menu
disableItem(strRecordId : String)
disables a menu item with the given id; this ID is the jsxid attribute on the record adhereing to the JSX Common Data Format (CDF);
int
Sets the validation state for the menu and returns the validation state.
jsx3.gui.Menu
enableItem(strRecordId : String, bEnabled : boolean)
enables a menu item with the given id by removing its 'jsxselected'; this ID is the jsxid attribute on the record adhereing to the JSX Common Data Format (CDF);
jsx3.gui.Menu
executeRecord(strRecordId : String)
Executes the specific jsxexecute code for the menu record.
void
Returns the JSX GUI object that owns (contains) the context item (a CDF record) being acted upon.
void
Returns the CDF record ID for the context item being acted upon.
int
Returns whether this menu renders a visual divider on its left side.
String
Returns url for 16x16 pixel image (preferably a gif with a transparent background); returns null if no image specified or an empty string
String
Returns the jsxid value in the CDF for the menu item last executed; returns null if unavailable
static String
Deprecated.
boolean
isItemEnabled(strRecordId : String)
Returns whether a record is enabled.
boolean
isItemSelected(strRecordId : String)
Returns whether a record is selected.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Menu
resets the cached DHTML content; hides any open menu; when the menu is next expanded (repainted), the update will be relected
jsx3.gui.Menu
selectItem(strRecordId : String, bSelected : boolean)
flags a a menu item as being selected; if the menu item is part of a group (e.g.
jsx3.gui.Menu
setDivider(intDivider : int, bRecalc : boolean)
Sets whether this menu renders a visual divider on its left side.
jsx3.gui.Menu
setImage(strURL : String)
Sets url for 16x16 pixel image (preferably a gif with a transparent background); returns a reference to self to facilitate method chaining
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState, setValue
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUND

static String DEFAULTBACKGROUND
background-image:url(JSX/images/menu/bg.gif);backround-repeat:repeat-y; (default)

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#ffffff (default)

DEFAULTCONTEXTLEFTOFFSET

static int DEFAULTCONTEXTLEFTOFFSET

DEFAULTXSLCACHEID

static String DEFAULTXSLCACHEID
Deprecated.
JSX_MENU_XSL (default)

DEFAULTXSLURL

static String DEFAULTXSLURL

NODATAMESSAGE

static String NODATAMESSAGE
Deprecated.
Constructor Detail

init

void init(strName : String, strText : String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
strTexttext for the menu (the persistent on-screen anchor that one would click to expand the menu); if the menu is only used as a context menu, this can be left null and the display property for the menu should be set to null
Method Detail

clearCachedContent

void clearCachedContent()
Deprecated. No-op.

deselectItem

jsx3.gui.Menu deselectItem(strRecordId : String)
flags a a menu item as being unselected (the default state)

Parameters:

strRecordIdthe jsxid property on the record node corresponding to the menu item to be deselected

Returns:

this object.  

disableItem

jsx3.gui.Menu disableItem(strRecordId : String)
disables a menu item with the given id; this ID is the jsxid attribute on the record adhereing to the JSX Common Data Format (CDF);

Parameters:

strRecordIdthe jsxid property on the record node corresponding to the menu item to be disabled

Returns:

this object.  

doValidate

int doValidate()
Sets the validation state for the menu and returns the validation state.

Returns:

jsx3.gui.Form.STATEVALID  

Overrides:


enableItem

jsx3.gui.Menu enableItem(strRecordId : String, bEnabled : boolean)
enables a menu item with the given id by removing its 'jsxselected'; this ID is the jsxid attribute on the record adhereing to the JSX Common Data Format (CDF);

Parameters:

strRecordIdthe jsxid property on the record node corresponding to the menu item to be enabled
bEnabledif false then disable the item

Returns:

this object.  

executeRecord

jsx3.gui.Menu executeRecord(strRecordId : String)
Executes the specific jsxexecute code for the menu record. This method also fires EXECUTE event for this menu but only under the deprecated 3.0 model event protocol.

Parameters:

strRecordIdid for the record whose code will be fire/execute

Returns:

this object  

getContextParent

void getContextParent()
Returns the JSX GUI object that owns (contains) the context item (a CDF record) being acted upon. For example, when a context menu is shown by right-clicking on a list tree, a ref to the tree/list is persisted as this value.

getContextRecordId

void getContextRecordId()
Returns the CDF record ID for the context item being acted upon. For example, when a context menu is shown by right-clicking on a row in a list or a node in a tree, the CDF record ID corresponding to the clicked item is persisted as this value.

getDivider

int getDivider()
Returns whether this menu renders a visual divider on its left side.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

getImage

String getImage()
Returns url for 16x16 pixel image (preferably a gif with a transparent background); returns null if no image specified or an empty string

Returns:

valid URL  

getValue

String getValue()
Returns the jsxid value in the CDF for the menu item last executed; returns null if unavailable

Returns:

 

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

isItemEnabled

boolean isItemEnabled(strRecordId : String)
Returns whether a record is enabled.

Parameters:

strRecordIdthe jsxid property on the record node to query

Returns:

 

isItemSelected

boolean isItemSelected(strRecordId : String)
Returns whether a record is selected.

Parameters:

strRecordIdthe jsxid property on the record node to query.

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


redrawRecord

jsx3.gui.Menu redrawRecord()
resets the cached DHTML content; hides any open menu; when the menu is next expanded (repainted), the update will be relected

Returns:

this object  

Overrides:


selectItem

jsx3.gui.Menu selectItem(strRecordId : String, bSelected : boolean)
flags a a menu item as being selected; if the menu item is part of a group (e.g., when the record node has an attribute called 'jsxgroupname'), all other menu items belonging to that group will be deselected

Parameters:

strRecordIdthe jsxid property on the record node corresponding to the menu item to be selected
bSelectedif false then deselect the item

Returns:

this object.  

setDivider

jsx3.gui.Menu setDivider(intDivider : int, bRecalc : boolean)
Sets whether this menu renders a visual divider on its left side. The divider is useful for visually separating this menu from the next menu to the left.

Parameters:

intDividerjsx3.Boolean.TRUE or jsx3.Boolean.FALSE.
bRecalcif true, the view will be updated without requiring a repaint.

Returns:

this object.  

setImage

jsx3.gui.Menu setImage(strURL : String)
Sets url for 16x16 pixel image (preferably a gif with a transparent background); returns a reference to self to facilitate method chaining

Parameters:

strURLvalid URL

Returns:

this object  

jsx3.gui

class NumberInput

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.TextBox
          ->jsx3.gui.NumberInput

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class NumberInput
extends jsx3.gui.TextBox
A form element (text box) that stores a number value. The value can be formatted according to a number format. User input is parsed according to the number format before setting the value of the form element.

Since:

3.7

See Also:

jsx3.util.NumberFormat,

Method Summary
String | int
Returns the number format as set with setFormat().
void
setFormat(format : String | int)
Sets the format of this number input.
Methods Inherited From jsx3.gui.TextBox
beep, doValidate, formatValue, getDefaultValue, getMaxLength, getReadonly, getType, getValidationExpression, getValidationType, getValue, getWrap, paint, parseValue, setDefaultValue, setMaxLength, setOverflow, setReadonly, setType, setValidationExpression, setValidationType, setValue, setWrap
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

getFormat

String | int getFormat()
Returns the number format as set with setFormat().

Returns:

 

See Also:


setFormat

void setFormat(format : String | int)
Sets the format of this number input. The format should conform to the syntax of jsx3.util.NumberFormat. The provided format may also be an integer, in which case it is intepreted as one of of the fields of NumberFormat - NUMBER, INTEGER, or CURRENCY - and the displayed format will be localized accordingly.

Parameters:

formatthe new format.

See Also:


jsx3.gui

class Painted

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted

All Implemented Interfaces:

jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.gui.Block, jsx3.gui.Sound

abstract class Painted
extends jsx3.app.Model
Abstract superclass of model objects that are painted to screen.

Since:

3.1

Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
HTMLElement
gives focus to the on-screen VIEW for the element; returns a handle to the html/dhtml element as exposed by the native browser
Object<String, int>
Returns the absolute positioning of the object's on-screen view in relation to JSXROOT (whose left/top is 0/0).
String
getAttribute(strName : String)
Returns the value for the custom attribute with the given name.
Object<String, String>
Returns handle to the JavaScript Object Array containing all events for the JSX GUI object; NOTE: This object will contain zero or more JavaScript Objects with the following Properties: script, type, system
String
Returns the value of the dynamic property @strPropName; if not found, returns null
HTMLElement
Returns handle/reference to the JSX GUI Object's on-screen counterpart—basically a handle to a DHTML object such as a DIV, SPAN, etc
jsx3.gui.Painted
Deprecated. Replaced with paintChild().
protected void
A hook that subclasses of Painted may override in order to perform additional manipulation of the HTML DOM created by the paint method.
protected void
Subclass if restoring of the CSS display of the object necessitates any cleanup of the view.
abstract String
Returns the DHTML, used for this object's on-screen VIEW
void
paintChild(objChild : jsx3.gui.Painted, bGroup : boolean, objGUI : HTMLElement, bCascadeOnly : boolean)
Paints a child of this object without repainting this entire object.
String
Iterates through children and returns concatenation of paint() method for all children.
void
recalcBox(properties : Array)
Removes the box model abstraction for a given object and its descendants.
jsx3.gui.Painted
removeAttribute(strName : String)
removes the specific custom property bound to this object; returns a reference to self (this) to facilitate method chaining
jsx3.gui.Painted
removes all events bound to this object; NOTE: The object must still be painted/repainted for its corresponding on-screen view to be likewise updated; returns a reference to self (this) to facilitate method chaining
String
Updates the view of this object by calling paint() and replacing the current view with the returned HTML.
jsx3.gui.Painted
setAttribute(strName : String, strValue : String)
Sets a property on the object that when the object is rendered on-screen, the HTML tag will be assigned the given name/value pair as a tag attribute
jsx3.gui.Painted
setDynamicProperty(strName : String, strValue : String, bNoSave : boolean)
Assigns a dynamic property to one of this object's instance properties.
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

focus

HTMLElement focus()
gives focus to the on-screen VIEW for the element; returns a handle to the html/dhtml element as exposed by the native browser

Returns:

 

getAbsolutePosition

Object<String, int> getAbsolutePosition(objRoot : HTMLElement, objGUI : HTMLElement)
Returns the absolute positioning of the object's on-screen view in relation to JSXROOT (whose left/top is 0/0). Returns information as a JavaScript object with properties, L, T, W, H of @objRoot is null, the on-screen view for JSXROOT is used as the object reference

Parameters:

objRootobject reference to IE DOM object (i.e., div, span, etc); if null is passed, the first div child of JSXROOT's on-screen representation will be used
objGUIobject reference to item to get absolute position for—as opposed to this instance (useful for determining placement of html objects contained by JSX objects, but not part of the actual JSX DOM)

Returns:

JScript object with properties: L, T, W, H (corresponding to left, top width, height)  

getAttribute

String getAttribute(strName : String)
Returns the value for the custom attribute with the given name.

Parameters:

strNamethe name of the attribute.

Returns:

the value of the attribute or undefined if no such attribute exists.  

getAttributes

Object<String, String> getAttributes()
Returns handle to the JavaScript Object Array containing all events for the JSX GUI object; NOTE: This object will contain zero or more JavaScript Objects with the following Properties: script, type, system

Returns:

 

getDynamicProperty

String getDynamicProperty(strName : String)
Returns the value of the dynamic property @strPropName; if not found, returns null

Parameters:

strNameproperty on this GUI object that will now use a dynamic property (e.g., 'jsxleft','jsxtop','jsxheight',etc.);

Returns:

value of the property  

getRendered

HTMLElement getRendered(objGUI : Object | jsx3.gui.Event)
Returns handle/reference to the JSX GUI Object's on-screen counterpart—basically a handle to a DHTML object such as a DIV, SPAN, etc

Parameters:

objGUIeither the HTML document containing the rendered object or an HTML element in that document. This argument is optional but improves the efficiency of this method if provided.

Returns:

IE DHTML object  

insertHTML

jsx3.gui.Painted insertHTML(objChild : jsx3.gui.Painted)
Deprecated. Replaced with paintChild().
Paints a child of this object without repainting this entire object. The child is inserted into the view of this object as the last child object, regardless of its actual position relative to other children. This method has no effect if this object is not currently painted.

Parameters:

objChildthe child object to paint.

Returns:

this object. 

See Also:


onAfterPaint

protected void onAfterPaint(objGUI : HTMLElement)
A hook that subclasses of Painted may override in order to perform additional manipulation of the HTML DOM created by the paint method. The order of steps follows. All steps occur in a single browser thread so that the screen does not update between steps 2 and 3.
  1. The paint() method of this object is called.
  2. The result of the paint() method is inserted into the HTML DOM.
  3. The onAfterPaint() method of this object is called, passing in the newly inserted root HTML element.

Parameters:

objGUIthe rendered HTML element representing this object.

Since:

3.4

onAfterRestoreView

protected void onAfterRestoreView(objGUI : HTMLElement)
Subclass if restoring of the CSS display of the object necessitates any cleanup of the view. For example, restoring a Matrix that was painted while it (or an ancestor) had a CSS display setting of 'none' results in the content height being mistaken as 0 (null).

Parameters:

objGUIthe rendered HTML element representing this object.

Since:

3.5

paint

abstract String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

paintChild

void paintChild(objChild : jsx3.gui.Painted, bGroup : boolean, objGUI : HTMLElement, bCascadeOnly : boolean)
Paints a child of this object without repainting this entire object. The child is inserted into the view of this object as the last child object, regardless of its actual position relative to other children. This method has no effect if this object is not currently painted.

Parameters:

objChildthe child object to paint.
bGrouptrue if this method is being called iteratively over a collection of children. This parameter will only be false on the final call in the iteration.
objGUI
bCascadeOnly

paintChildren

String paintChildren(c : Array<jsx3.gui.Painted>)
Iterates through children and returns concatenation of paint() method for all children.

Parameters:

cthe children to paint. If not provided this.getChildren() is used.

Returns:

DHTML  

recalcBox

void recalcBox(properties : Array)
Removes the box model abstraction for a given object and its descendants. This effectively resets the box profiler, so dimensions can be recalculated as if the object was just broought into the visual DOM.

Parameters:

propertiesWill designate by name, those properties that should be updated on the object's VIEW (without requiring the MODEL to repaint), including one or more of the following: padding, margin, border

removeAttribute

jsx3.gui.Painted removeAttribute(strName : String)
removes the specific custom property bound to this object; returns a reference to self (this) to facilitate method chaining

Parameters:

strNamethe name of the custom property to remove

Returns:

this object  

removeAttributes

jsx3.gui.Painted removeAttributes()
removes all events bound to this object; NOTE: The object must still be painted/repainted for its corresponding on-screen view to be likewise updated; returns a reference to self (this) to facilitate method chaining

Returns:

this object  

repaint

String repaint()
Updates the view of this object by calling paint() and replacing the current view with the returned HTML. This method has no effect if this object is not currently displayed.

Returns:

the result of calling paint() or null if this object is not displayed. 

See Also:


setAttribute

jsx3.gui.Painted setAttribute(strName : String, strValue : String)
Sets a property on the object that when the object is rendered on-screen, the HTML tag will be assigned the given name/value pair as a tag attribute

Parameters:

strNamethe name of the property/attribute
strValuethe value for the property; may not contain double-quotes; escape via jsx3.util.strEscapeHTML if necessary or use combinations of single-quotes and escaped single-quotes

Returns:

this object (this)  

setDynamicProperty

jsx3.gui.Painted setDynamicProperty(strName : String, strValue : String, bNoSave : boolean)
Assigns a dynamic property to one of this object's instance properties.

Parameters:

strNameproperty on this GUI object that will now use a dynamic property (e.g., 'jsxleft','jsxtop','jsxheight',etc.);
strValuename of a dynamic style, whose value will be used
bNoSaveWhen true, this dynamic property will not be serialized with the object.

Returns:

this object  

jsx3.gui

class RadioButton

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.RadioButton

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class RadioButton
extends jsx3.gui.Block
A GUI control that implements a single radio button.

Several radio buttons may be organized into a group ("radio group") with the groupName property. No more than one radio button of the set of radio buttons sharing a single groupName value may be selected at one time.

Field Summary
static String
jsx30radio
static int
Value for the selected field indicating a selected radio button.
static int
Value for the selected field indicating an unselected radio button.
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strText : String, strValue : String, strGroupName : String, intSelected : int)
The instance initializer.
Method Summary
int
Validates that this radio button is selected if it is required.
int
Returns the default selection state of this radio button.
String
Returns the group name of this radio button, which is equivalent to the name property on a standard HTML radio button.
String
Returns the value of the selected radio button in the radio group of this radio button.
int
Returns the current selection state of this radio button.
Array<jsx3.gui.RadioButton>
getSiblings(bRendered : boolean)
Returns the list of sibling radio buttons.
static String
getValue(strGroupName : String)
Deprecated. Use getGroupValue() instead.
String
Returns the value of this radio button.
static String
Deprecated.
String
Returns the serialized DHTML representation of this object.
jsx3.gui.RadioButton
setDefaultSelected(intSelected : int)
Sets the default selection state of this radio button.
void
setGroupName(strGroupName : String)
Sets the group name of this radio button.
void
setGroupValue(strValue : String)
Sets the selected radio button of the radio group of this radio button by value.
jsx3.gui.RadioButton
setSelected(intSelected : int, objGUI : Object)
Sets the current selection state of this radio button.
static jsx3.gui.RadioButton
setValue(strGroupName : String, strValue : String)
Deprecated. Use setGroupValue() instead.
jsx3.gui.RadioButton
setValue(strValue : String)
Sets the value of this radio button.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30radio

SELECTED

static final int SELECTED
Value for the selected field indicating a selected radio button.

UNSELECTED

static final int UNSELECTED
Value for the selected field indicating an unselected radio button.
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strText : String, strValue : String, strGroupName : String, intSelected : int)
The instance initializer.

Parameters:

strNamea unique name distinguishing this object from all other JSX GUI objects in the JSX application.
vntLeftthe left offset of this object from the parent container as a number (in pixels) or a string css value.
vntTopthe top offset of this object from the parent container as a number (in pixels) or a string css value.
vntWidththe width of this object as a number (in pixels) or a string css value.
vntHeightthe height of this object as a number (in pixels) or a string css value.
strTextthe text/HTML markup to display with the radio button.
strValuethe value of the radio button (equivalent to the value property on a standard HTML radio button).
strGroupNamethe group name of the radio button (equivalent to the name property on a standard HTML radio button).
intSelectedthe default selection state of the radio button. SELECTED or UNSELECTED. null is equivalent to SELECTED.
Method Detail

doValidate

int doValidate()
Validates that this radio button is selected if it is required. A radiobutton will pass validation if it is optional or if it is required and it or one of its sibling radio buttons is selected.

Returns:

jsx3.gui.Form.STATEVALID or jsx3.gui.Form.INSTATEVALID.  

Overrides:


getDefaultSelected

int getDefaultSelected()
Returns the default selection state of this radio button. To get the current state use getSelected().

Returns:

SELECTED or UNSELECTED

See Also:


getGroupName

String getGroupName()
Returns the group name of this radio button, which is equivalent to the name property on a standard HTML radio button.

Returns:

 

getGroupValue

String getGroupValue()
Returns the value of the selected radio button in the radio group of this radio button.

Returns:

the value of the selected radio button or null if no button is selected.  

getSelected

int getSelected()
Returns the current selection state of this radio button.

Returns:

SELECTED or UNSELECTED

See Also:

,

getSiblings

Array<jsx3.gui.RadioButton> getSiblings(bRendered : boolean)
Returns the list of sibling radio buttons. This list is comprised of the radio buttons whose groupName property is equal to the groupName property of this radio button. The return value does not include this radio button. This method will only return siblings if this radio button is rendered and will only return sibling radio buttons that are also rendered on screen.

Parameters:

bRendered

Returns:

 

getValue

static String getValue(strGroupName : String)
Deprecated. Use getGroupValue() instead.
Returns the value of the selected radio button in a given radio group. If no radio button in the group is selected, null is returned. This method only queries radio groups that are currently rendered on screen.

Parameters:

strGroupNamethe name of the radio group to search.

Returns:

the value of the selected radio button in the radio group. 

Overrides:

See Also:


getValue

String getValue()
Returns the value of this radio button. When this radio button is selected, the value of its radio group is equal to the value of this radio button.

Returns:

the value of this radio button.  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the serialized DHTML representation of this object.

Returns:

 

Overrides:


setDefaultSelected

jsx3.gui.RadioButton setDefaultSelected(intSelected : int)
Sets the default selection state of this radio button.

Parameters:

intSelectedSELECTED or UNSELECTED.

Returns:

this object.  

setGroupName

void setGroupName(strGroupName : String)
Sets the group name of this radio button. If this property is set, this radio button will be a member of the set of radio buttons sharing the same value for this property. No more than one member of this set may be selected at one time.

Parameters:

strGroupNamethe new group name.

setGroupValue

void setGroupValue(strValue : String)
Sets the selected radio button of the radio group of this radio button by value.

Parameters:

strValuethe value of the radio button of the radio group of this radio button to select.

setSelected

jsx3.gui.RadioButton setSelected(intSelected : int, objGUI : Object)
Sets the current selection state of this radio button. This method immediately updates the view of this object if it is currently rendered on the screen. If intSelected is equal to SELECTED any other radio buttons in the radio group of this object will be unselected.

Parameters:

intSelectedif SELECTED or null, this object is selected, otherwise it is unselected.
objGUI

Returns:

this object.  

setValue

static jsx3.gui.RadioButton setValue(strGroupName : String, strValue : String)
Deprecated. Use setGroupValue() instead.
Sets the selected radio button in a given radio group.

Parameters:

strGroupNamethe name of the radio group to search.
strValuethe value of the radio button in the radio group to select.

Returns:

the selected radio button. 

Overrides:

See Also:


setValue

jsx3.gui.RadioButton setValue(strValue : String)
Sets the value of this radio button.

Parameters:

strValuethe value of this radiobutton. In general, each radio button is a radio group has a unique value.

Returns:

this object.  

Overrides:


jsx3.gui

class Select

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Select

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Select
extends jsx3.gui.Block
The JSX version of a standard GUI select box. XML drives the contents of the select box.

This class requires a CDF data source. The supported CDF attributes are:

Field Summary
static String
The URL of the arrow image.
static String
Deprecated.
static String
Deprecated. Renamed to DEFAULTXSLURL.
static String
Deprecated.
static String
jsx30select_select
static String
Deprecated. This value is now localized.
static String
The URL of the default XSL template of a normal select box.
static String
Deprecated. This value is now localized.
static String
Deprecated. This value is now localized.
static String
The URL of the mouse over background image.
static String
The URL of the selected background image.
static String
Deprecated.
static String
Deprecated. Renamed to DEFAULTXSLURL.
static int
The number of milliseconds of delay for the combo typeahead function.
static int
Value of the type field indicating a combo select box.
static int
Value of the type field indicating a normal select box.
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strSelectedValue : String)
The instance initializer.
Method Summary
int
Returns STATEVALID if this select box is not required or if it is required and its value is not empty.
HTMLElement
Gives focus to this select box.
String
Returns the text to display in this select box if the value of this select box is null.
String
getIcon(strDefault : String)
Returns the URL to use for the dropdown image.
int
Returns the maximum length allowed for the input field of this combo control.
String
If this is a normal select box returns the value of the jsxtext attribute of the selected CDF record, or if this is a combo select box returns the current value.
int
Returns the type of this select box.
String
Returns the value of this select box.
static String
Deprecated.
jsx3.xml.Document
Returns the XSL appropriate to the select type (either combo or select) if no custom XSLT is specified.
void
hide(bFocus : boolean)
Hides the drop-down portion of this select control.
String
Returns the DHTML representation of this select box.
jsx3.gui.Select
redrawRecord(strRecordId : String, intAction : int)
Redraws one record from the CDF data source of this select box.
jsx3.gui.Select
setDefaultText(strDefaultText : String)
Sets the text to display in this select box if the value of this select box is null.
void
setIcon(strPath : String)
Sets the URL to use for the dropdown image (16x16).
jsx3.gui.Select
setMaxLength(intMaxLength : int)
Sets the maximum length allowed for the input field of this combo control.
jsx3.gui.Select
setText(strText : String)
Deprecated.
jsx3.gui.Select
setType(TYPE : int)
Sets the type of this select box.
jsx3.gui.Select
setValue(strRecordId : String)
Sets the selected record of this select control.
void
Displays the list of options for this select box.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ARROWICON

static String ARROWICON
The URL of the arrow image.

COMBOXSLID

static String COMBOXSLID
Deprecated.
The default XSL id of a combo select box.

COMBOXSLURL

static String COMBOXSLURL
Deprecated. Renamed to DEFAULTXSLURL.
The URL of the default XSL template of a combo select box.

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
Deprecated.
The default background color of a select box.

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30select_select

DEFAULTTEXT

static String DEFAULTTEXT
Deprecated. This value is now localized.
The text label of the null record when no record is selected.

DEFAULTXSLURL

static String DEFAULTXSLURL
The URL of the default XSL template of a normal select box.

NODATAMESSAGE

static String NODATAMESSAGE
Deprecated. This value is now localized.

NOMATCHMESSAGE

static String NOMATCHMESSAGE
Deprecated. This value is now localized.

OVERIMAGE

static String OVERIMAGE
The URL of the mouse over background image.

SELECTEDIMAGE

static String SELECTEDIMAGE
The URL of the selected background image.

SELECTXSLID

static String SELECTXSLID
Deprecated.
The default XSL id of a normal select box.

SELECTXSLURL

static String SELECTXSLURL
Deprecated. Renamed to DEFAULTXSLURL.

TYPEAHEADDELAY

static int TYPEAHEADDELAY
The number of milliseconds of delay for the combo typeahead function.

TYPECOMBO

static final int TYPECOMBO
Value of the type field indicating a combo select box.

TYPESELECT

static final int TYPESELECT
Value of the type field indicating a normal select box.
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strSelectedValue : String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
strSelectedValuethis value should correspond to the XML value for the node whose text should be preloaded in the select box when it is painted
Method Detail

doValidate

int doValidate()
Returns STATEVALID if this select box is not required or if it is required and its value is not empty. If this select is of type combo then any value other than an empty string is valid, otherwise only values corresponding to an actual CDF record of this select are valid.

Returns:

jsx3.gui.Form.STATEVALID or jsx3.gui.Form.STATEINVALID.  

Overrides:


focus

HTMLElement focus()
Gives focus to this select box. If this is a combo select, this method gives focus to the text edit box.

Returns:

the on-screen HTML element that was just given focus.  

Overrides:


getDefaultText

String getDefaultText()
Returns the text to display in this select box if the value of this select box is null. If no value has been explicitly set with setDefaultText() a value appropriate to the server locale is returned.

Returns:

 

getIcon

String getIcon(strDefault : String)
Returns the URL to use for the dropdown image. If not provided, the default system image will be used.

Parameters:

strDefault

Returns:

 

Since:

3.7

getMaxLength

int getMaxLength()
Returns the maximum length allowed for the input field of this combo control. This setting only has meaning if this control is of type TYPECOMBO.

Returns:

 

getText

String getText()
If this is a normal select box returns the value of the jsxtext attribute of the selected CDF record, or if this is a combo select box returns the current value.

Returns:

 

Overrides:


getType

int getType()
Returns the type of this select box.

Returns:

TYPESELECT or TYPECOMBO

See Also:

,

getValue

String getValue()
Returns the value of this select box. The value is the jsxid attribute of the selected CDF record.

Returns:

the value or null if no record is selected.  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getXSL

jsx3.xml.Document getXSL()
Returns the XSL appropriate to the select type (either combo or select) if no custom XSLT is specified.

Returns:

jsx3.xml.Document instance  

Overrides:


hide

void hide(bFocus : boolean)
Hides the drop-down portion of this select control.

Parameters:

bFocusif true, the form control will be focused after hiding the drop-down.

paint

String paint()
Returns the DHTML representation of this select box.

Returns:

DHTML  

Overrides:


redrawRecord

jsx3.gui.Select redrawRecord(strRecordId : String, intAction : int)
Redraws one record from the CDF data source of this select box. If strRecordId is equal to the selected record id, the text of this select box is set to the value of the record's jsxtext attribute.

Parameters:

strRecordIdthe id of the record that will be redrawn.
intActionINSERT, UPDATE, or DELETE.

Returns:

this object.  

Overrides:


setDefaultText

jsx3.gui.Select setDefaultText(strDefaultText : String)
Sets the text to display in this select box if the value of this select box is null.

Parameters:

strDefaultTextany valid string. HTML markup is allowed, but may cause unpredicatable effects.

Returns:

this object.  

setIcon

void setIcon(strPath : String)
Sets the URL to use for the dropdown image (16x16).

Parameters:

strPathThis URL will be resolved relative to the project path.

Since:

3.7

setMaxLength

jsx3.gui.Select setMaxLength(intMaxLength : int)
Sets the maximum length allowed for the input field of this combo control.

Parameters:

intMaxLength

Returns:

this object.  

setText

jsx3.gui.Select setText(strText : String)
Deprecated.
Sets the text to display in this select box while it is closed. This method does not affect the value of this select box, it simply affects the current view. This method does not affect the value returned by getText() either.

Parameters:

strTextthe text to display.

Returns:

this object. 

Overrides:

See Also:


setType

jsx3.gui.Select setType(TYPE : int)
Sets the type of this select box.

Parameters:

TYPETYPESELECT or TYPECOMBO.

Returns:

this object. 

See Also:

,

setValue

jsx3.gui.Select setValue(strRecordId : String)
Sets the selected record of this select control. Fires the SELECT event only under the deprecated 3.0 model event protocol.

Parameters:

strRecordIdid for the record that will be the selected item.

Returns:

this object.  

Overrides:


show

void show()
Displays the list of options for this select box.

jsx3.gui

class Slider

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Slider

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Slider
extends jsx3.gui.Block
A GUI control that implements a draggable slider. The slider is draggable along a fixed-length line representing a linear range of values. Events are provided for incremental drag events as well as the end drag (change) event.

The range of values of a slider is always [0,100]. 0 is at the far left side of a horizontal slider and bottom edge of a vertical slider. The value is available as a floating point number with the getValue() method as well as the event handlers.

Since:

3.1

Field Summary
static int
Orientation value for a horizontal slider.
static int
Orientation value for a vertical slider.
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntLength : int | String)
The instance initializer.
Method Summary
Number
constrainValue(fpValue : Number)
Constrains a possible slider value to a legal value.
int
Sets the validation state for this slider and returns the validation state.
String
Returns the URL of the image to use for the handle.
int | String
Returns the value of the length field, the size of the dimension along this slider axis.
int
Returns the orientation of this slider.
int
Returns whether the track is painted.
int
Returns whether clicking the track moves the handle to that point.
Number
Returns the value of this slider.
static String
Deprecated.
String
Paints this slider.
jsx3.gui.Slider
Sets the URL of the image to use for the handle.
jsx3.gui.Slider
setLength(vntLength : int | String, bRepaint : boolean)
Sets the length of this slider.
jsx3.gui.Slider
setOrientation(intValue : int)
Sets the orientation of this slider.
jsx3.gui.Slider
setPaintTrack(bValue : int)
Sets whether the track is painted.
jsx3.gui.Slider
Sets whether clicking the track moves the handle to that point.
jsx3.gui.Slider
setValue(fpValue : Number)
Sets the value of this slider and repositions the handle.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

HORIZONTAL

static final int HORIZONTAL
Orientation value for a horizontal slider.

VERTICAL

static final int VERTICAL
Orientation value for a vertical slider.
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntLength : int | String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntLengththe length of the control along the draggable axis
Method Detail

constrainValue

Number constrainValue(fpValue : Number)
Constrains a possible slider value to a legal value. This implementation ensures that the resulting value is within the legal range of [0,100].

Override this method on an instance of jsx3.gui.Slider to create a "notched" slider. The following code creates a slider that allows its handle to be in a location corresponding to a value that is a multiple of 10:
objSlider.constrainValue = function(fpValue) {
  return Math.max(0, Math.min(100, jsx3.util.numRound(fpValue, 10)));
}

Parameters:

fpValuethe value to validate, usually corresponds to a value along that slider that the handle is being dragged.

Returns:

the validated value, usually the nearest value to fpValue that is legal for this slider.  

doValidate

int doValidate()
Sets the validation state for this slider and returns the validation state.

Returns:

jsx3.gui.Form.STATEVALID.  

Overrides:


getHandleImage

String getHandleImage()
Returns the URL of the image to use for the handle.

Returns:

 

getLength

int | String getLength()
Returns the value of the length field, the size of the dimension along this slider axis.

Returns:

the length field  

getOrientation

int getOrientation()
Returns the orientation of this slider.

Returns:

HORIZONTAL or VERTICAL

See Also:

,

getPaintTrack

int getPaintTrack()
Returns whether the track is painted.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getTrackClickable

int getTrackClickable()
Returns whether clicking the track moves the handle to that point.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

getValue

Number getValue()
Returns the value of this slider.

Returns:

between 0 and 100.  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "3.0.00")

Returns:

 

paint

String paint()
Paints this slider.

Returns:

the serialized HTML.  

Overrides:


setHandleImage

jsx3.gui.Slider setHandleImage(strUrl : String)
Sets the URL of the image to use for the handle. If no URL is set, a default image is used.

Parameters:

strUrl

Returns:

this object.  

setLength

jsx3.gui.Slider setLength(vntLength : int | String, bRepaint : boolean)
Sets the length of this slider.

Parameters:

vntLengthe.g. 100[px] or "100%".
bRepaintwhether to repaint this slider immediately to reflect the change.

Returns:

this object.  

setOrientation

jsx3.gui.Slider setOrientation(intValue : int)
Sets the orientation of this slider.

Parameters:

intValueHORIZONTAL or VERTICAL.

Returns:

this object.  

setPaintTrack

jsx3.gui.Slider setPaintTrack(bValue : int)
Sets whether the track is painted.

Parameters:

bValuejsx3.Boolean.TRUE or jsx3.Boolean.FALSE.

Returns:

this object.  

setTrackClickable

jsx3.gui.Slider setTrackClickable(bValue : int)
Sets whether clicking the track moves the handle to that point.

Parameters:

bValuejsx3.Boolean.TRUE or jsx3.Boolean.FALSE.

Returns:

this object.  

setValue

jsx3.gui.Slider setValue(fpValue : Number)
Sets the value of this slider and repositions the handle.

Parameters:

fpValuethe new value, between 0 and 100.

Returns:

this object.  

Overrides:


jsx3.gui

class Sound

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Sound

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Sound
extends jsx3.gui.Painted
Class that provides an object-oriented interface for playing sounds in a GI application.

Note that playing sounds in Internet Explorer requires a plug-in. This class currently supports the following sound plug-ins: The installed plug-ins determine which sound file formats are supported.

Since:

3.1

Field Summary
static void
Apple Quicktime sound plugin type.
Constructor Summary
void
init(strName : String, strURL : String)
The instance initializer.
Method Summary
float
Returns the length of the sound in seconds.
String
Returns the full name and version number of the audio plugin used to play this sound.
float
Returns the current position (elapsed time) of the sound in seconds.
String
Returns the URL of the sound file.
int
Returns the volume that the sound plays at.
String
Paints the container for the sound.
void
Pauses the sound.
void
Plays the sound.
void
Stops and rewinds the sound.
void
setPosition(position : float)
Sets the current position (elapsed time) of the sound in seconds.
jsx3.gui.Sound
setURL(strURL : String)
Sets the URL of the sound file.
jsx3.gui.Sound
setVolume(intVolume : int)
Sets the volume of this sound.
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

QUICKTIME

static ? QUICKTIME
Apple Quicktime sound plugin type.
Constructor Detail

init

void init(strName : String, strURL : String)
The instance initializer.

Parameters:

strNamethe JSX name
strURLthe URL of the sound file to play
Method Detail

getLength

float getLength()
Returns the length of the sound in seconds.

Returns:

the length in seconds or NaN if the length can not be determined  

getPluginVersion

String getPluginVersion()
Returns the full name and version number of the audio plugin used to play this sound.

Returns:

 

getPosition

float getPosition()
Returns the current position (elapsed time) of the sound in seconds.

Returns:

the current position in seconds or NaN if the position can not be determined  

getURL

String getURL()
Returns the URL of the sound file.

Returns:

the URL of the sound file to play  

getVolume

int getVolume()
Returns the volume that the sound plays at.

Returns:

the volume to play the sound at, [0,100]  

paint

String paint()
Paints the container for the sound.

Returns:

 

Overrides:


pause

void pause()
Pauses the sound. Calling play() after calling pause() will play the sound from the point where it was paused.

play

void play()
Plays the sound.

rewind

void rewind()
Stops and rewinds the sound.

setPosition

void setPosition(position : float)
Sets the current position (elapsed time) of the sound in seconds.

Parameters:

positionthe new position in seconds

setURL

jsx3.gui.Sound setURL(strURL : String)
Sets the URL of the sound file.

Parameters:

strURLthe URL of the sound file to play

Returns:

this object  

setVolume

jsx3.gui.Sound setVolume(intVolume : int)
Sets the volume of this sound. The change takes effect immediately.

Parameters:

intVolumethe volume to play the sound at. 0 is mute, 100 is loudest

Returns:

this object  

jsx3.gui

class Splitter

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Splitter

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Splitter
extends jsx3.gui.Block
This class manages layouts by providing a container that will paint its first two child GUI objects separated by a 'splitter' (either vertical or horizontal). Split panes can contain any number of object types, but most commonly contain JSXBlock elements to aid in layout feautures such as padding, borders, etc.

Field Summary
static int
static int
Constructor Summary
void
init(strName : String, ORIENTATION : int)
instance initializer
Method Summary
int
Returns whether the user can resize this control
String
Returns the URL for the image to use for the splitter handle when the splitter is rendered side by side ( | ).
int
*Returns whether the splitter layout is top-over (--) or side-by-side (|).
int
Returns a valid integer representing the minimum size in pixels for the container; the default minimum is 1
String
Returns a valid percentage (e.g.
int
Returns a valid integer representing the minimum size in pixels for the container; the default minimum is 8
String
Returns the URL for the image to use for the splitter handle when the splitter is rendered top over bottom (--).
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Splitter
paintChild(objJSXChild : jsx3.app.Model, bGroup : ?)
subclassed method.
void
setEnabled(intEnabled : int)
Sets whether the user can resize this control.
jsx3.gui.Splitter
Sets the URL for the image to use for the splitter handle when the splitter is rendered side by side ( | ).
jsx3.gui.Splitter
setOrientation(ORIENTATION : int)
Returns whether the splitter layout is top-over (--) or side-by-side (|); returns reference to self to facilitate method chaining
jsx3.gui.Splitter
Sets the minimum size in pixels for the container; the default minimum is 1; returns reference to self to facilitate method chaining
jsx3.gui.Splitter
setSubcontainer1Pct(strSubcontainerPct : String, bView : boolean)
Sets a valid percentage (e.g.
jsx3.gui.Splitter
Sets the minimum size in pixels for the container; the default minimum is 8; returns reference to self to facilitate method chaining
jsx3.gui.Splitter
Sets the URL for the image to use for the splitter handle when the splitter is rendered top over bottom (--).
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ORIENTATIONH

static final int ORIENTATIONH

ORIENTATIONV

static final int ORIENTATIONV
Constructor Detail

init

void init(strName : String, ORIENTATION : int)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
ORIENTATIONconstant; either jsx3.gui.Splitter.ORIENTATIONH or jsx3.gui.Splitter.ORIENTATIONV; if none provided the default (horizontal layout) or vertical (stacked) layout)
Method Detail

getEnabled

int getEnabled()
Returns whether the user can resize this control

Returns:

0, 1, or null  

getHSplitImage

String getHSplitImage()
Returns the URL for the image to use for the splitter handle when the splitter is rendered side by side ( | ). When not set, Splitter.HSPLITIMAGE will be used when painted on-screen.

Returns:

 

getOrientation

int getOrientation()
*Returns whether the splitter layout is top-over (--) or side-by-side (|).

Returns:

 

getSubcontainer1Min

int getSubcontainer1Min()
Returns a valid integer representing the minimum size in pixels for the container; the default minimum is 1

Returns:

 

getSubcontainer1Pct

String getSubcontainer1Pct()
Returns a valid percentage (e.g., 100.00% 23.567%) that will be applied to the on-screen element as its CSS width/height percentage

Returns:

 

getSubcontainer2Min

int getSubcontainer2Min()
Returns a valid integer representing the minimum size in pixels for the container; the default minimum is 8

Returns:

 

getVSplitImage

String getVSplitImage()
Returns the URL for the image to use for the splitter handle when the splitter is rendered top over bottom (--). When not set, Splitter.VSPLITIMAGE will be used when painted on-screen.

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


paintChild

jsx3.gui.Splitter paintChild(objJSXChild : jsx3.app.Model, bGroup : ?)
subclassed method. routes call to repaint() as splitters cannot insert directly into the DOM

Parameters:

objJSXChilddirect child whose generated VIEW will be directly inserted into the DOM to provide more efficient screen updates as repaint is costly for large applications
bGroup

Returns:

this object  

Overrides:


setEnabled

void setEnabled(intEnabled : int)
Sets whether the user can resize this control.

Parameters:

intEnabled0 or 1. Note: null is equivalent to 1.

setHSplitImage

jsx3.gui.Splitter setHSplitImage(strURL : String)
Sets the URL for the image to use for the splitter handle when the splitter is rendered side by side ( | ).

Parameters:

strURLvalid URL. If no background image is wanted, pass an empty string. The resize bar for a side-by-side orientation is 8 pixels wide with a variable height; the image will be placed at background position, 'center center', and will not repeat.

Returns:

this object  

setOrientation

jsx3.gui.Splitter setOrientation(ORIENTATION : int)
Returns whether the splitter layout is top-over (--) or side-by-side (|); returns reference to self to facilitate method chaining

Parameters:

ORIENTATIONconstant; either jsx3.gui.Splitter.ORIENTATIONH or jsx3.gui.Splitter.ORIENTATIONV

Returns:

this object  

setSubcontainer1Min

jsx3.gui.Splitter setSubcontainer1Min(intMin : int)
Sets the minimum size in pixels for the container; the default minimum is 1; returns reference to self to facilitate method chaining

Parameters:

intMininteger value represnting the minimum size in pixels for the container

Returns:

this object  

setSubcontainer1Pct

jsx3.gui.Splitter setSubcontainer1Pct(strSubcontainerPct : String, bView : boolean)
Sets a valid percentage (e.g., 100% 23.567%) that will be applied to the on-screen element as its CSS width/height percentage. If pixels are the preferred unit, you may use an integer and a wild card (*) to apply the value to either container. For example, 100,* or *,250.

Parameters:

strSubcontainerPctvalid CSS width property as a percentage (e.g., 34.56%) or as an integer/wildcard pair (e.g., 100,*)
bViewfalse if null; if true the view is updated automatically without a repaint

Returns:

this object  

setSubcontainer2Min

jsx3.gui.Splitter setSubcontainer2Min(intMin : int)
Sets the minimum size in pixels for the container; the default minimum is 8; returns reference to self to facilitate method chaining

Parameters:

intMininteger value represnting the minimum size in pixels for the container

Returns:

this object  

setVSplitImage

jsx3.gui.Splitter setVSplitImage(strURL : String)
Sets the URL for the image to use for the splitter handle when the splitter is rendered top over bottom (--).

Parameters:

strURLvalid URL. If no background image is wanted, pass an empty string. The resize bar for a top-over-bottom orientation is 8 pixels hight with a variable width; the image will be placed at background position, 'center center', and will not repeat.

Returns:

this object  

jsx3.gui

class Stack

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Stack

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Stack
extends jsx3.gui.Block
This class is equivalent to a tab, but uses the stack metaphor; like a tab, it has one child—a block for its content; a jsx3.gui.Stack instance should only be contained by a jsx3.gui.StackGroup instance for proper rendering.

Field Summary
static String
#aaccff
static String
static String
border:solid 1px #9898a5;border-left-color:#ffffff;border-top-color:#ffffff;
static String
#ffffff
static String
#e8e8f5
static int
1
static int
0 (default)
Constructor Summary
void
init(strName : String, strCaption : String)
instance initializer
Method Summary
void
Makes this stack the visible (expanded) stack in the parent stack group.
void
Deprecated. use doShow() instead.
void
overrides method is superclass; ensures the stack is expanded before giving focus
String
Returns valid CSS property value, (i.e.
jsx3.app.Model
Returns the child of this stack that will be painted as the content of this stack.
String
Returns valid CSS property value, (i.e.
static String
Deprecated.
boolean
Returns whether or not this stack is the active (expanded) stack
boolean
onSetParent(objParent : ?)
is called when an item is about to be set; returns false if the parent is not of the appropriate type; in this case, the parent must be a jsx3.gui.List or derivative class
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Stack
setActiveColor(strActiveColor : String)
Sets valid CSS property value, (i.e.
jsx3.gui.Stack
setInactiveColor(strInactiveColor : String)
Sets valid CSS property value, (i.e.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ACTIVECOLOR

static String ACTIVECOLOR
#aaccff

BACKGROUND

static String BACKGROUND

BORDER

static String BORDER
border:solid 1px #9898a5;border-left-color:#ffffff;border-top-color:#ffffff;

CHILDBGCOLOR

static String CHILDBGCOLOR
#ffffff

INACTIVECOLOR

static String INACTIVECOLOR
#e8e8f5

ORIENTATIONH

static final int ORIENTATIONH
1

ORIENTATIONV

static final int ORIENTATIONV
0 (default)
Constructor Detail

init

void init(strName : String, strCaption : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
strCaptionif != null, will be set as the text property (label) for the stack
Method Detail

doShow

void doShow()
Makes this stack the visible (expanded) stack in the parent stack group.

doShowStack

void doShowStack()
Deprecated. use doShow() instead.
Makes this stack the visible (expanded) stack in the parent stack group. Invokes the EXECUTE model event only under the deprecated 3.0 model event protocol. Invokes the SHOW model event.

See Also:


focus

void focus()
overrides method is superclass; ensures the stack is expanded before giving focus

Overrides:


getActiveColor

String getActiveColor()
Returns valid CSS property value, (i.e., red, #ffffff) when caption bar for stack is moused over. Default: jsx3.gui.Stack.ACTIVECOLOR

Returns:

valid CSS property value, (i.e., red, #ffffff)  

getContentChild

jsx3.app.Model getContentChild()
Returns the child of this stack that will be painted as the content of this stack. This implementation returns the first child that is not a menu or a toolbar button.

Returns:

 

getInactiveColor

String getInactiveColor()
Returns valid CSS property value, (i.e., red, #ffffff) when caption bar for stack is moused out. Default: jsx3.gui.Stack.INACTIVECOLOR

Returns:

valid CSS property value, (i.e., red, #ffffff)  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

isFront

boolean isFront()
Returns whether or not this stack is the active (expanded) stack

Returns:

 

onSetParent

boolean onSetParent(objParent : ?)
is called when an item is about to be set; returns false if the parent is not of the appropriate type; in this case, the parent must be a jsx3.gui.List or derivative class

Parameters:

objParent

Returns:

true to allow the set, false to veto  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setActiveColor

jsx3.gui.Stack setActiveColor(strActiveColor : String)
Sets valid CSS property value, (i.e., red, #ffffff) when caption bar for stack is moused over; returns reference to self to facilitate method chaining

Parameters:

strActiveColorvalid CSS property value, (i.e., red, #ffffff)

Returns:

this object  

setInactiveColor

jsx3.gui.Stack setInactiveColor(strInactiveColor : String)
Sets valid CSS property value, (i.e., red, #ffffff) when caption bar for stack is moused out; returns reference to self to facilitate method chaining

Parameters:

strInactiveColorvalid CSS property value, (i.e., red, #ffffff)

Returns:

this object  

jsx3.gui

class StackGroup

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.LayoutGrid
          ->jsx3.gui.StackGroup

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class StackGroup
extends jsx3.gui.LayoutGrid
similar to how a tabbed pane manages a collection of tabs, the stack group is a parent container that manages JSXStack instances

Field Summary
static int
27 (default)
static Array<String>
Deprecated.
static int
Deprecated.
static int
1 : side-by-side (|) layout
static int
0 : top-over (--) layout (default)
Constructor Summary
void
init(strName : String)
The instance initializer.
Method Summary
int
Returns the size of the handle common to all child stack instances (in pixels).
int
int
Returns zero-based index for the tab that is active per its placement in the child JScript array
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.StackGroup
setBarSize(intBarSize : int)
Sets the size of the handle for the child stack instances; returns reference to self to facilitate method chaining
jsx3.gui.StackGroup
setOrientation(intOrientation : int)
Methods Inherited From jsx3.gui.LayoutGrid
getBestGuess, getCols, getDimensionArray, getRepeat, getRows, setBestGuess, setCols, setDimensionArray, setRepeat, setRows
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBARSIZE

static int DEFAULTBARSIZE
27 (default)

DEFAULTDIMENSIONS

static Array<String> DEFAULTDIMENSIONS
Deprecated.
["27","*"] (default)

DEFAULTSTACKCOUNT

static int DEFAULTSTACKCOUNT
Deprecated.
2 (default)

ORIENTATIONH

static final int ORIENTATIONH
1 : side-by-side (|) layout

ORIENTATIONV

static final int ORIENTATIONV
0 : top-over (--) layout (default)
Constructor Detail

init

void init(strName : String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

getBarSize

int getBarSize()
Returns the size of the handle common to all child stack instances (in pixels). Default: jsx3.gui.StackGroup.DEFAULTBARSIZE

Returns:

size in pixels  

getOrientation

int getOrientation()

Returns:

 

Overrides:


getSelectedIndex

int getSelectedIndex()
Returns zero-based index for the tab that is active per its placement in the child JScript array

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setBarSize

jsx3.gui.StackGroup setBarSize(intBarSize : int)
Sets the size of the handle for the child stack instances; returns reference to self to facilitate method chaining

Parameters:

intBarSizesize (in pixels)

Returns:

this object  

setOrientation

jsx3.gui.StackGroup setOrientation(intOrientation : int)

Parameters:

intOrientation

Returns:

this object.  

Overrides:


jsx3.gui

class Tab

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Tab

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Tab
extends jsx3.gui.Block
Renders a tab in a tabbed pane. An instance of this class must be child of an instance of jsx3.gui.TabbedPane. A tab should have exactly one child, usually a jsx3.gui.Block, which holds all of its content.

See Also:

jsx3.gui.TabbedPane

Field Summary
static String
static String
#e8e8f5
static String
#e8e8f5
static String
static String
Deprecated.
static String
#d8d8e5
static String
Deprecated.
static String
static int
0 : disabled
static int
1 : enabled (default)
Constructor Summary
void
init(strName : String, strText : String, vntWidth : int | String, strHexActiveColor : String, strHexInactiveColor : String)
instance initializer
Method Summary
jsx3.gui.Tab
doClickTab(bFocus : boolean, bForce : boolean)
Deprecated. replaced with doShow()
void
Brings this tab and its associated pane forward in the stack among all sibling tabs.
String
Returns the CSS background-color property value, (i.e.
String
Returns background image that will underlay each tab to provide an outset-type border.
jsx3.app.Model
Returns the child of this tab that will be painted as the content of this tab.
int
Returns the state for the tab control.
String
Returns the CSS background-color property value, (i.e.
static String
Deprecated.
boolean
Returns whether or not this stack is the active (expanded) stack
boolean
onSetParent(objParent : ?)
Called when an item is about to be set; returns false if the parent is not of the appropriate type; in this case, the parent must be a jsx3.gui.TabbedPane or derivative class
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Tab
setActiveColor(strActiveColor : String)
Sets the CSS background-color property value, (i.e.
jsx3.gui.Tab
setBevel(strURL : String)
Sets background image that will underlay each tab to provide an outset-type border; if this value is not set or null is passed, the default background image for the jsx3.gui.Tab class will be use the contant value, jsx3.gui.Tab.DEFAULTBEVELIMAGE;
jsx3.gui.Tab
setEnabled(STATE : int)
Sets the enabled state for the tab control; returns reference to self to facilitate method chaining
jsx3.gui.Tab
setInactiveColor(strInactiveColor : String)
Sets the CSS background-color property value, (i.e.
jsx3.gui.Tab
setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ACTIVEBEVEL

static String ACTIVEBEVEL

CHILDBGCOLOR

static String CHILDBGCOLOR
#e8e8f5

DEFAULTACTIVECOLOR

static String DEFAULTACTIVECOLOR
#e8e8f5

DEFAULTBEVELIMAGE

static String DEFAULTBEVELIMAGE

DEFAULTHIGHLIGHT

static String DEFAULTHIGHLIGHT
Deprecated.
#f6f6ff

DEFAULTINACTIVECOLOR

static String DEFAULTINACTIVECOLOR
#d8d8e5

DEFAULTSHADOW

static String DEFAULTSHADOW
Deprecated.
#a6a6af

INACTIVEBEVEL

static String INACTIVEBEVEL

STATEDISABLED

static final int STATEDISABLED
0 : disabled

STATEENABLED

static final int STATEENABLED
1 : enabled (default)
Constructor Detail

init

void init(strName : String, strText : String, vntWidth : int | String, strHexActiveColor : String, strHexInactiveColor : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
strTexttext to display within the given tab; if null, jsx3.gui.Tab.DEFAULTTEXT is used
vntWidthone of: 1) the width as an integer representing a fixed pixel width for the tab (e.g., 80) ; 2) the width as a percentage representing this tab's width as a percentage of how wide the entire tabbed pane should be (e.g., "25%"); 3) no value (null) to designate that this tab should be just large engough to contain the value of the parameter, @strText;
strHexActiveColorvalid css property for defining the color to use when the tab is active (i.e., red, #ff0000, etc)
strHexInactiveColorvalid css property for defining the color to use when the tab is inactive (i.e., red, #ff0000, etc)
Method Detail

doClickTab

jsx3.gui.Tab doClickTab(bFocus : boolean, bForce : boolean)
Deprecated. replaced with doShow()
Brings this tab and its associated pane forward in the stack among all sibling tabs. This method invokes the EXECUTE event only under the deprecated 3.0 event protocol.

Parameters:

bFocusif null, assume true; if false, do not give focus to the tab's on-screen VIEW
bForcefalse if null; to avoid updating the VIEW, tabs ignore click events if they're already the active tab; this will override and force the click to occur

Returns:

this object 

See Also:


doShow

void doShow()
Brings this tab and its associated pane forward in the stack among all sibling tabs. If the tab handle is rendered but is scrolled out of view due to too many sibling tabs, the tab handle will be scrolled into view. To apply cursor focus to the tab, follow this method with a call to setFocus.

See Also:


getActiveColor

String getActiveColor()
Returns the CSS background-color property value, (i.e., red, #ffffff) to apply when the tab is active (front). If this value is not set, it will use the default, jsx3.gui.Tab.DEFAULTACTIVECOLOR

Returns:

 

getBevel

String getBevel()
Returns background image that will underlay each tab to provide an outset-type border. Default: jsx3.gui.Tab.DEFAULTBEVELIMAGE

Returns:

valid url (typically relative) to point to an image that can be used as a bacground image for the tab  

getContentChild

jsx3.app.Model getContentChild()
Returns the child of this tab that will be painted as the content of this tab. This implementation returns the first child of this stack.

Returns:

 

getEnabled

int getEnabled()
Returns the state for the tab control. Default: jsx3.gui.Tab.STATEENABLED

Returns:

one of: jsx3.gui.Tab.STATEDISABLED, jsx3.gui.Tab.STATEENABLED  

getInactiveColor

String getInactiveColor()
Returns the CSS background-color property value, (i.e., red, #ffffff) to apply when the tab is inactive (not front). If this value is not set, it will use the default, jsx3.gui.Tab.DEFAULTINACTIVECOLOR

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

isFront

boolean isFront()
Returns whether or not this stack is the active (expanded) stack

Returns:

 

onSetParent

boolean onSetParent(objParent : ?)
Called when an item is about to be set; returns false if the parent is not of the appropriate type; in this case, the parent must be a jsx3.gui.TabbedPane or derivative class

Parameters:

objParent

Returns:

true to allow the set, false to veto  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setActiveColor

jsx3.gui.Tab setActiveColor(strActiveColor : String)
Sets the CSS background-color property value, (i.e., red, #ffffff) to apply when the tab is active (front). If this value is not set, it will use the default, jsx3.gui.Tab.DEFAULTACTIVECOLOR

Parameters:

strActiveColor

Returns:

this object  

setBevel

jsx3.gui.Tab setBevel(strURL : String)
Sets background image that will underlay each tab to provide an outset-type border; if this value is not set or null is passed, the default background image for the jsx3.gui.Tab class will be use the contant value, jsx3.gui.Tab.DEFAULTBEVELIMAGE;

Parameters:

strURLvalid url (typically relative) to point to an image that can be used as a bacground image for the tab

Returns:

this object  

setEnabled

jsx3.gui.Tab setEnabled(STATE : int)
Sets the enabled state for the tab control; returns reference to self to facilitate method chaining

Parameters:

STATEone of: jsx3.gui.Tab.STATEDISABLED, jsx3.gui.Tab.STATEENABLED

Returns:

this object  

setInactiveColor

jsx3.gui.Tab setInactiveColor(strInactiveColor : String)
Sets the CSS background-color property value, (i.e., red, #ffffff) to apply when the tab is inactive (not front). If this value is not set, it will use the default, jsx3.gui.Tab.DEFAULTINACTIVECOLOR

Parameters:

strInactiveColor

Returns:

this object  

setText

jsx3.gui.Tab setText(strText : String, bRepaint : boolean)
Sets the text/HTML for the control to be displayed on-screen; returns reference to self to facilitate method chaining;

Parameters:

strTexttext/HTML
bRepaintif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

 

Overrides:


jsx3.gui

class TabbedPane

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.TabbedPane

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class TabbedPane
extends jsx3.gui.Block
Renders a tabbed pane, which consists of a set of tabs, only one of which is visible at a time.

See Also:

jsx3.gui.Tab

Field Summary
static int
50
static int
20 (default)
static String
jsx:///images/tab/l.png
static String
jsx:///images/tab/r.png
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
int
Returns the zero-based child index of the active child tab.
void
whether or not to show the tabs of the tabbed pane.
int
Returns the CSS height property (in pixels) for child tabs
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.TabbedPane
setSelectedIndex(intIndex : int | jsx3.gui.Tab, bRepaint : boolean)
Sets the active tab of this tabbed pane.
void
setShowTabs(intShowTabs : ?)
whether or not to show the tabs of the tabbed pane.
jsx3.gui.TabbedPane
setTabHeight(intTabHeight : int)
Sets the CSS height property for the object (in pixels) for child tabs; returns reference to self to facilitate method chaining
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

AUTO_SCROLL_INTERVAL

static int AUTO_SCROLL_INTERVAL
50

DEFAULTTABHEIGHT

static int DEFAULTTABHEIGHT
20 (default)

LSCROLLER

static String LSCROLLER
jsx:///images/tab/l.png

RSCROLLER

static String RSCROLLER
jsx:///images/tab/r.png
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

getSelectedIndex

int getSelectedIndex()
Returns the zero-based child index of the active child tab.

Returns:

 

getShowTabs

void getShowTabs()
whether or not to show the tabs of the tabbed pane. if false then only the content of each tab is drawn.

getTabHeight

int getTabHeight()
Returns the CSS height property (in pixels) for child tabs

Returns:

height (in pixels)  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "3.0.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setSelectedIndex

jsx3.gui.TabbedPane setSelectedIndex(intIndex : int | jsx3.gui.Tab, bRepaint : boolean)
Sets the active tab of this tabbed pane. Pass either the zero-based child index of the tab to activate or the tab itself.

Parameters:

intIndex
bRepaintif true, immediately updates the view to reflect the new active tab.

Returns:

this object.  

setShowTabs

void setShowTabs(intShowTabs : ?)
whether or not to show the tabs of the tabbed pane. if false then only the content of each tab is drawn.

Parameters:

intShowTabs

setTabHeight

jsx3.gui.TabbedPane setTabHeight(intTabHeight : int)
Sets the CSS height property for the object (in pixels) for child tabs; returns reference to self to facilitate method chaining

Parameters:

intTabHeightheight (in pixels)

Returns:

this object  

jsx3.gui

class Table

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Table

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Table
extends jsx3.gui.Block
A lightweight control that displays CDF data in an HTML table. Supports both single- and multi-selection modes. Data can be sorted by clicking on column labels. Output and output formatting can be customized using a combination of XSLT, inline CSS properties, or named CSS rules. The columns for this control are defined within the object model and are not defined in the DOM as child objects.

The Table class by default supports the following CDF attributes: This class publishes the following model events:

Since:

3.5

Field Summary
static String
static jsx3.xml.Document
Default XSL template for rendering the cell value for all cells.
static int
20
static String
jsx:///images/table/select.gif
static int
Enum value for the multiSelect property indicating a single-select table.
static int
Enum value for the multiSelect property indicating a multi-select table.
static int
Enum value for the multiSelect property indicating an unselectable table.
static String
ascending
static String
jsx:///images/table/sort_asc.gif (default)
static String
descending
static String
jsx:///images/table/sort_desc.gif (default)
static String
number
static String
text (default)
Constructor Summary
void
init(strName : String)
instance initializer
Method Summary
void
Deselects all selected CDF records.
void
deselectRecord(strRecordId : String)
Deselects a CDF record within the Table.
void
doSort(intSortDir : String)
Sorts according to the current sort path.
int
validates the Table; if the Table is set to 'required', a selection must be made to pass validation.
void
focusRowById(strCdfId : String)
Applies focus to the on-screen row indentified by the CDF record id that generated it
String
Returns the CSS rule for the HTML row element(s) containing the alternating table data rows.
String
Returns the CSS properties for the HTML row element(s) containing the alternating table data rows.
int
Returns whether the table is sortable.
String
Returns the CSS rule that will be applied to every HTML cell in the body of the table.
String
Returns the CSS properties that will be inlined on every HTML cell in the body of the table.
String
Returns the string of XML in CDF format representing the Column Profile Document.
jsx3.xml.CDF.Document
Returns a clone of the CDF document used internally to define the Columns (text, order, mapped attributes, etc).
HTMLElement
getContentElement(strCdfId : String, strAttName : String)
Returns the on-screen cell that represents the intersection of the row identified by strCdfId and the first cell mapped to the named CDF attribute, strAttName.
String
getHeaderClass(strDefault : String)
Returns the CSS rule for the HTML row containing the column headers.
int
getHeaderHeight(strDefault : String)
Returns the height of the header row in pixels.
String
getHeaderStyle(strDefault : String)
Returns the CSS style for the HTML row containing the column headers.
String
Returns the text/HTML to display on-screen when the xml/xsl transformation for this object results in a null or empty result set
String
getRenderingContext(strDefault : String)
Returns the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.
String
Returns the CSS rule for the HTML row element(s) containing the table data.
String
Returns the CSS properties for the HTML row elements(s) containing the table data.
Array<String>
Returns the jsxid(s) for the selected record(s).
jsx3.util.List<jsx3.xml.Entity>
Returns the collection of selected records.
String
getSelectionBG(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus
int
getSelectionModel(strDefault : String)
Returns the selection model.
String
Returns the direction (jsx3.gui.Table.SORT_ASCENDING or jsx3.gui.Table.SORT_DESCENDING) for the sorted column; if no direction specified, ascending is returned
String
Returns the name of the CDF attribute to sort on.
String
Returns the data type to be used for sorting this list.
String | Array<String>
Returns an array of selected values (or empty array) if the selection model is Table.SELECTION_MULTI_ROW.
String
getValueTemplate(strDefault : String)
Gets the user-defined XSL template (xsl:template) that will override the defualt template defined by Table.DEFAULT_CELL_VALUE_TEMPLATE.
int
getWrap(strDefault : String)
Returns whether or not the table's data cells support text-wrapping and expand vertically to display their wrapped content.
jsx3.xml.Document
Returns XSLT for the Table, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Table
redrawRecord(strRecordId : ?, ACTION : ?)
This method implements redraw support by repainting the entire control.
void
Paints only the data rows.
void
Paints only the header row.
void
selectRecord(strRecordId : String)
Selects a CDF record of this list.
void
setAlternateRowClass(strRuleName : String)
Sets the CSS rule for the HTML row element(s) containing the alternating table data rows.
void
Sets the CSS properties for the HTML row element(s) containing the alternating table data rows.
void
setCanSort(SORT : int)
Sets whether the table is sortable.
void
setCellClass(strRuleName : String)
Sets the CSS rule that will be applied to every HTML cell in the body of the table.
void
setCellStyle(strCSS : String)
Sets the CSS properties that will be inlined on every HTML cell in the body of the table.
void
Sets a string of XML (in CDF format) or an actual jsx3.xml.CDF.Document instance representing the Column Profile Document.
void
setHeaderClass(strRuleName : String)
Sets the CSS rule for the HTML row containing the column headers.
void
setHeaderHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the height of the header row in pixels.
void
Sets the CSS style properties for the HTML row containing the column headers.
void
setRenderingContext(strJsxId : String, bSuppressRepaint : boolean)
Sets the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.
void
setRowClass(strRuleName : String)
Sets the CSS rule for the HTML row element(s) containing the table data.
void
setRowStyle(strCSS : String)
Sets the CSS properties for the HTML row element(s) containing the table data.
void
Sets the URL for the image to use (as the repeating background image) to denote selection.
void
setSelectionModel(intType : int)
Sets the selection model
void
setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.
void
setSortPath(strAttr : String)
Sets the name of the CDF attribute to sort on.
void
setSortType(DATATYPE : String)
Sets the data type for the list.
jsx3.gui.Table
setValue(strId : String | Array<String>)
Sets the value of this table.
void
setValueTemplate(TEMPLATE : String)
Sets the user-defined XSL template that will override the defualt template defined by Table.DEFAULT_CELL_VALUE_TEMPLATE.
void
setWrap(WRAP : int)
Sets whether or not the table's data cells support text-wrapping and expand vertically to display their wrapped content.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTXSLURL

static String DEFAULTXSLURL

DEFAULT_CELL_VALUE_TEMPLATE

static jsx3.xml.Document DEFAULT_CELL_VALUE_TEMPLATE
Default XSL template for rendering the cell value for all cells. This template can be replaced with a custom XSL template. The template should match on a record element (match="record") and will be used for all data cells in the body of the table. This template will be passed one named parameter (xsl:param) named attname, the name of the attribute to which the column is mapped.

DEFAULT_HEADER_HEIGHT

static int DEFAULT_HEADER_HEIGHT
20

SELECTION_BG

static String SELECTION_BG
jsx:///images/table/select.gif

SELECTION_MULTI_ROW

static final int SELECTION_MULTI_ROW
Enum value for the multiSelect property indicating a single-select table.

SELECTION_ROW

static final int SELECTION_ROW
Enum value for the multiSelect property indicating a multi-select table.

SELECTION_UNSELECTABLE

static final int SELECTION_UNSELECTABLE
Enum value for the multiSelect property indicating an unselectable table.

SORT_ASCENDING

static final String SORT_ASCENDING
ascending

SORT_ASCENDING_IMG

static String SORT_ASCENDING_IMG
jsx:///images/table/sort_asc.gif (default)

SORT_DESCENDING

static final String SORT_DESCENDING
descending

SORT_DESCENDING_IMG

static String SORT_DESCENDING_IMG
jsx:///images/table/sort_desc.gif (default)

TYPE_NUMBER

static final String TYPE_NUMBER
number

TYPE_TEXT

static final String TYPE_TEXT
text (default)
Constructor Detail

init

void init(strName : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
Method Detail

deselectAllRecords

void deselectAllRecords()
Deselects all selected CDF records.

deselectRecord

void deselectRecord(strRecordId : String)
Deselects a CDF record within the Table. Both the view and the data model (CDF) will be updated

Parameters:

strRecordIdthe jsxid of the record to deselect.

doSort

void doSort(intSortDir : String)
Sorts according to the current sort path. If no sort direction is specified, the sort direction will be toggled.

Parameters:

intSortDirjsx3.gui.Table.SORT_ASCENDING or jsx3.gui.Table.SORT_DESCENDING.

See Also:

,

doValidate

int doValidate()
validates the Table; if the Table is set to 'required', a selection must be made to pass validation. Otherwise, a Table will always pass validation

Returns:

one of: jsx3.gui.Form.STATEINVALID or jsx3.gui.Form.STATEVALID  

Overrides:


focusRowById

void focusRowById(strCdfId : String)
Applies focus to the on-screen row indentified by the CDF record id that generated it

Parameters:

strCdfIdjsxid property for the corresponding CDF record

getAlternateRowClass

String getAlternateRowClass(strDefault : String)
Returns the CSS rule for the HTML row element(s) containing the alternating table data rows.

Parameters:

strDefault

Returns:

 

getAlternateRowStyle

String getAlternateRowStyle(strDefault : String)
Returns the CSS properties for the HTML row element(s) containing the alternating table data rows.

Parameters:

strDefault

Returns:

 

getCanSort

int getCanSort()
Returns whether the table is sortable. If null or jsx3.Boolean.TRUE, the instance is sortable.

Returns:

 

getCellClass

String getCellClass()
Returns the CSS rule that will be applied to every HTML cell in the body of the table.

Returns:

 

getCellStyle

String getCellStyle()
Returns the CSS properties that will be inlined on every HTML cell in the body of the table.

Returns:

 

getColumnProfile

String getColumnProfile()
Returns the string of XML in CDF format representing the Column Profile Document.

Returns:

 

getColumnProfileDocument

jsx3.xml.CDF.Document getColumnProfileDocument()
Returns a clone of the CDF document used internally to define the Columns (text, order, mapped attributes, etc). The order of the records in this document reflects the order of the columns in the Table. If the column profile document defined by getColumnProfile is not a valid XML document, an empty CDF Document will be returned instead. Note that if you make changes to the Document returned by this method, those changes will only be reflected by calling setColumnProfile (to update the model), followed by a call to repaint (to update the view).

Returns:

 

See Also:


getContentElement

HTMLElement getContentElement(strCdfId : String, strAttName : String)
Returns the on-screen cell that represents the intersection of the row identified by strCdfId and the first cell mapped to the named CDF attribute, strAttName.

Parameters:

strCdfIdjsxid property for CDF record
strAttNameattribute name on the CDF record. For example, jsxtext

Returns:

 

getHeaderClass

String getHeaderClass(strDefault : String)
Returns the CSS rule for the HTML row containing the column headers.

Parameters:

strDefault

Returns:

 

getHeaderHeight

int getHeaderHeight(strDefault : String)
Returns the height of the header row in pixels. If this value is not set (null), the list will render with the default value of jsx3.gui.Table.DEFAULT_HEADER_HEIGHT.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getHeaderStyle

String getHeaderStyle(strDefault : String)
Returns the CSS style for the HTML row containing the column headers.

Parameters:

strDefault

Returns:

 

getNoDataMessage

String getNoDataMessage()
Returns the text/HTML to display on-screen when the xml/xsl transformation for this object results in a null or empty result set

Returns:

text/HTML  

getRenderingContext

String getRenderingContext(strDefault : String)
Returns the jsxid of the CDF record that will serve as the origin when rendering the data on-screen. If not set, the id, jsxroot, (which is the id for the root node, <data>) will be used.

Parameters:

strDefaultThe default value to use if null

Returns:

 

getRowClass

String getRowClass()
Returns the CSS rule for the HTML row element(s) containing the table data.

Returns:

 

getRowStyle

String getRowStyle()
Returns the CSS properties for the HTML row elements(s) containing the table data.

Returns:

 

getSelectedIds

Array<String> getSelectedIds()
Returns the jsxid(s) for the selected record(s). Equivalent to this.getValue() except that the return value is always an Array.

Returns:

JavaScript array of stings  

getSelectedNodes

jsx3.util.List<jsx3.xml.Entity> getSelectedNodes()
Returns the collection of selected records.

Returns:

 

getSelectionBG

String getSelectionBG(strDefault : String)
Returns the CSS string to apply to a Row/Cell when it has focus

Parameters:

strDefaultThe default value to use if null (Table.SELECTION_BG)

Returns:

 

getSelectionModel

int getSelectionModel(strDefault : String)
Returns the selection model. If no selection type is specified, the instance will employ single row selection (SELECTION_ROW)

Parameters:

strDefaultThe default value to use if null

Returns:

 

getSortDirection

String getSortDirection()
Returns the direction (jsx3.gui.Table.SORT_ASCENDING or jsx3.gui.Table.SORT_DESCENDING) for the sorted column; if no direction specified, ascending is returned

Returns:

one of: jsx3.gui.Table.SORT_ASCENDING or jsx3.gui.Table.SORT_DESCENDING  

getSortPath

String getSortPath()
Returns the name of the CDF attribute to sort on. If no value is set an empty string is returned by default.

Returns:

 

getSortType

String getSortType()
Returns the data type to be used for sorting this list.

Returns:

jsx3.gui.Table.TYPE_TEXT or jsx3.gui.Table.TYPE_NUMBER  

getValue

String | Array<String> getValue()
Returns an array of selected values (or empty array) if the selection model is Table.SELECTION_MULTI_ROW. Returns a string (or null) for the other selection models

Returns:

 

Overrides:


getValueTemplate

String getValueTemplate(strDefault : String)
Gets the user-defined XSL template (xsl:template) that will override the defualt template defined by Table.DEFAULT_CELL_VALUE_TEMPLATE.

Parameters:

strDefaultxsl:template

Returns:

 

getWrap

int getWrap(strDefault : String)
Returns whether or not the table's data cells support text-wrapping and expand vertically to display their wrapped content. If this property is not set, the cell content will not wrap.

Parameters:

strDefault

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getXSL

jsx3.xml.Document getXSL()
Returns XSLT for the Table, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default

Returns:

jsx3.xml.Document instance containing valid XSL stylesheet  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


redrawRecord

jsx3.gui.Table redrawRecord(strRecordId : ?, ACTION : ?)
This method implements redraw support by repainting the entire control.

Parameters:

strRecordId
ACTION

Returns:

this object  

Overrides:


repaintData

void repaintData()
Paints only the data rows. Call for quick repainting of the data rows when only the source data has changed. Does not recalculate and reprofile the box profile and resulting XSLT. Retains scroll position when possible.

repaintHead

void repaintHead()
Paints only the header row. Call for quick repainting of the header row and not the data rows.

selectRecord

void selectRecord(strRecordId : String)
Selects a CDF record of this list. The item will be highlighted in the view and the CDF data will be updated accordingly. If this list is a multi-select list then this selection will be added to any previous selection.

Parameters:

strRecordIdthe jsxid of the record to select.

setAlternateRowClass

void setAlternateRowClass(strRuleName : String)
Sets the CSS rule for the HTML row element(s) containing the alternating table data rows. Multiple rules are supported. For example: bodyText, normalText.

Parameters:

strRuleName

setAlternateRowStyle

void setAlternateRowStyle(strCSS : String)
Sets the CSS properties for the HTML row element(s) containing the alternating table data rows. Multiple properties are supported. For example: background-color:red;font-family:Arial;.

Parameters:

strCSS

setCanSort

void setCanSort(SORT : int)
Sets whether the table is sortable.

Parameters:

SORTone of jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

setCellClass

void setCellClass(strRuleName : String)
Sets the CSS rule that will be applied to every HTML cell in the body of the table. Multiple rules are supported. For example: boldText titleText.

Parameters:

strRuleName

setCellStyle

void setCellStyle(strCSS : String)
Sets the CSS properties that will be inlined on every HTML cell in the body of the table. Multiple properties are supported. For example: text-align:right;background-color:#eeeeee;border-bottom:solid 1px #aeaeae;.

Parameters:

strCSS

setColumnProfile

void setColumnProfile(objCDF : String | jsx3.xml.CDF.Document)
Sets a string of XML (in CDF format) or an actual jsx3.xml.CDF.Document instance representing the Column Profile Document. Each record in this document defines the profile for a column in the Table. The following attributes are supported on each record:
  • jsxid: The unique ID for the record (REQUIRED).
  • jsxtext: HTML or text content to use as the column label.
  • jsxwidth: The width of the column (pixel units are implied). For example: 300, or 25%.
  • jsxpath: The name of the attribute to which this column maps (REQUIRED).
  • jsxpathtype: The data type for the attribute. One of: text (default) or number.


For example:
  <data jsxid="jsxroot">
    <record jsxid="a1" jsxtext="&lt;b&gt;Column 1&lt;/b&gt;" jsxpath="jsxtext"/>
    <record jsxid="a2" jsxtext="Column 2" jsxwidth="100" jsxpath="value" jsxpathtype="number"/>
  </data>

Parameters:

objCDF

setHeaderClass

void setHeaderClass(strRuleName : String)
Sets the CSS rule for the HTML row containing the column headers. Multiple rules are supported. For example: boldText titleText. The following CSS properties (those affecting layout and position) are not allowed for the rule: width, height, left, top, position, overflow, border, padding, margin.

Parameters:

strRuleName

setHeaderHeight

void setHeaderHeight(intHeight : int, bSuppressRepaint : boolean)
Sets the height of the header row in pixels. Set to zero (0) to hide the header row and only render the body rows.

Parameters:

intHeight
bSuppressRepaintPass true to stop the default repaint from occurring. Typically property updates that affect the browser-specific box model (such as height) are repainted immediately to keep the box model abstraction in sync with the native view. However, the repaint can be suppressed to avoid unnecessary reparsing of the XSLT during repeated property updates.

setHeaderStyle

void setHeaderStyle(strCSS : String)
Sets the CSS style properties for the HTML row containing the column headers. Multiple properties are supported. For example: background-image:url(JSXAPPS/myproject/images/bg.gif);font-family:Arial;. The following CSS properties (those affecting layout and position) are not allowed: width, height, left, top, position, overflow, border, padding, margin.

Parameters:

strCSS

setRenderingContext

void setRenderingContext(strJsxId : String, bSuppressRepaint : boolean)
Sets the jsxid of the CDF record that will serve as the origin when rendering the data on-screen.

Parameters:

strJsxIdjsxid property for the CDF record to use as the contextual root when rendering data on-screen.
bSuppressRepaintPass true to stop the default repaint from occurring.

setRowClass

void setRowClass(strRuleName : String)
Sets the CSS rule for the HTML row element(s) containing the table data. Every row will apply the rule defined by this value, unless an alternate row rule is used, in which case, the rule (classname) is alternated between this value and the value applied by setAlternateRowClass. Multiple rules are supported. For example: bodyText normalText.

Parameters:

strRuleName

See Also:


setRowStyle

void setRowStyle(strCSS : String)
Sets the CSS properties for the HTML row element(s) containing the table data. Every row will apply the properties defined by this value, unless an alternate row style is used, in which case, the properties are alternated between this value and the value applied by setAlternateRowStyle. Multiple properties are supported. For example: background-color:white;font-family:Arial;.

Parameters:

strCSS

See Also:


setSelectionBG

void setSelectionBG(strURL : String)
Sets the URL for the image to use (as the repeating background image) to denote selection.

Parameters:

strURL

setSelectionModel

void setSelectionModel(intType : int)
Sets the selection model

Parameters:

intTypeone of Table: .SELECTION_UNSELECTABLE, .SELECTION_ROW, .SELECTION_MULTI_ROW

setSortDirection

void setSortDirection(intSortDir : String)
Sets the direction (ascending or descending) for the sorted column.

Parameters:

intSortDirone of: jsx3.gui.Table.SORT_ASCENDING or jsx3.gui.Table.SORT_DESCENDING

setSortPath

void setSortPath(strAttr : String)
Sets the name of the CDF attribute to sort on. The records in the data source of this table are sorted on this attribute before being painted to screen.

Parameters:

strAttr

setSortType

void setSortType(DATATYPE : String)
Sets the data type for the list.

Parameters:

DATATYPEdata type for this column's data. Valid types include: jsx3.gui.Table.TYPE_TEXT and jsx3.gui.Table.TYPE_NUMBER

setValue

jsx3.gui.Table setValue(strId : String | Array<String>)
Sets the value of this table. Deselects all existing selections. Scrolls the first record into view.

Parameters:

strIdjsxid attribute for the CDF record(s) to select

Returns:

this object.  

Overrides:


setValueTemplate

void setValueTemplate(TEMPLATE : String)
Sets the user-defined XSL template that will override the defualt template defined by Table.DEFAULT_CELL_VALUE_TEMPLATE. The template must resolve to a valid XSL Template when parsed. The template should match on a record (match="record"). The template will be passed a single XSL param (xsl:param) named attname.

Parameters:

TEMPLATEvalid xsl:template

setWrap

void setWrap(WRAP : int)
Sets whether or not the table's data cells support text-wrapping and expand vertically to display their wrapped content.

Parameters:

WRAPjsx3.Boolean.TRUE or jsx3.Boolean.FALSE

jsx3.gui

class Template

Object
->jsx3.lang.Object
  ->jsx3.gui.Template

class Template
extends jsx3.lang.Object
Provides template related services to the base template class, jsx3.gui.Template.Block. See the compile method for usage details.

Since:

3.6

Nested Class Summary
jsx3.gui.Template.Block
Provides base class for creating custom GUI classes.
Constructor Summary
void
instance initializer
Method Summary
static void
addLibrary(strLibraryId : String, arrLibrary : Array<Object>)
Adds a resolver library.
static Object
addResolver(strSetId : String, strResolverId : String, objResolver : Object, META : Object)
Adds a resolver to a given resolver set.
static void
compile(Markup : String | jsx3.xml.Document, objClass : jsx3.lang.Class, bCache : boolean)
Converts an HTML template into the relevant JavaScript functions needed by the GUI class.
static String
precompile(strClassName : String, strPrototypeName : String, strQualifiedName : String)
Call this method during GUI class development to see how your XML template is converted into JavaScript by the template compiler.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init()
instance initializer
Method Detail

addLibrary

static void addLibrary(strLibraryId : String, arrLibrary : Array<Object>)
Adds a resolver library. A resolver library is a collection of one or more resolvers. Libraries allow resolvers belonging to different sets to be organized into a related group. This simplifies how resolvers are grouped and used as they are shared among classes. Note that a library is automatically created for each class that uses the template engine. For example, if a GUI class named my.Example is compiled by the template, a library will be created named my.Example. Any other GUI class can now use every resolver made available to my.Example, by importing this named library.

Parameters:

strLibraryIdThe ID for this library.
arrLibraryAn array of objects. Each object has the named properties: id, setid (optional if id is prefixed with a $).

addResolver

static Object addResolver(strSetId : String, strResolverId : String, objResolver : Object, META : Object)
Adds a resolver to a given resolver set.

Parameters:

strSetIdIf not provided, the global resolver ID will be used: jsx3.gui.Template
strResolverIdUnique ID for the resolver among all resolvers in this set
objResolverfunction handler. The resolver always executes in context of the instance being painted
METAExtended configuration object with named properties:
  • type (css (default)| attribute | event | box)
  • repaintupdate (true | false (default))
  • name (the name of the attribute or style (i.e., background-color))
  • triggers (array of named triggers that will cause this resolver to update when called)
  • defaultvalue (if the resovler function returns null, this value will be used)

Returns:

Resolver object just created  

compile

static void compile(Markup : String | jsx3.xml.Document, objClass : jsx3.lang.Class, bCache : boolean)
Converts an HTML template into the relevant JavaScript functions needed by the GUI class. See jsx3.gui.Template.Block for example usage.

Parameters:

MarkupString of XML that validates against the Schema, http://gi.tibco.com/transform/
objClassAn instance of jsx3.lang.Class
bCache

Throws:

{jsx3.lang.Exception}if strMarkup does not validate or objClass is not an instance of jsx3.lang.Class

See Also:


precompile

static String precompile(strClassName : String, strPrototypeName : String, strQualifiedName : String)
Call this method during GUI class development to see how your XML template is converted into JavaScript by the template compiler. Using the precompiled JavaScript can provide to-the-line debugging information when difficult bugs appear in your GUI class. To use for testing, copy the JavaScript code returned by this method and paste into your GUI class. Make sure that when you paste it, it is the last statement contained by the class. If you paste the generated JavaScript BEFORE the call to 'getTemplateXML', it will be clobbered by the generated code. The code returned by this method reflects the exact methods and properties injected by the template class when it converts the markup returned by getTemplateXML into JavaScript.

Parameters:

strClassNameThe name of the class to precompile. For example, WIDGET. This should also be the name of the class as contained within the defineClass method where the given class is instantiated
strPrototypeNameOptional. The prototype name per the class declaration. For example, widget
strQualifiedNameOptional. The full name of the class, including the package (use if the class does not belong to the jsx3.gui package). For example, jsx3.ext.SomeRedBoxClass

Returns:

JavaScript function code  

jsx3.gui

class Template.Block

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Template.Block

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class Template.Block
extends jsx3.gui.Block
Provides base class for creating custom GUI classes. Example usage:

//step 1) require the template engine (and all used interfaces)
jsx3.require("jsx3.gui.Template");
 
//step 2) define the new class
jsx3.lang.Class.defineClass(
  "my.custom.Widget",            //fully qualified name
  jsx3.gui.Template.Block,       //super class
  [],                            //interface(s)
  function(WIDGET, widget) {     //class alias, prototype alias
     
    //step 3) define the init method
    widget.init = function(strName) {
      this.jsxsuper(strName);
    };
     
    //step 4) define the MODEL defaults
    WIDGET.XYZ = 'xyz';          //CLASS defaults
    widget.xyz = 'xyz';          //prototype defaults
     
    //step 5) define the VIEW template
    widget.getTemplateXML = function() {
     return ['<transform version="1.0" ' ,
     '  xmlns="http://gi.tibco.com/transform/" ' ,
     '  xmlns:u="http://gi.tibco.com/transform/user">' ,
     '  <template>' ,
     '    <div onclick="{onclick}" ' ,
     '      style="position:{$position};left:{$left};background:{bg|red};">' ,
     '      <text>{mytext|some default text}</text>' ,
     '    </div>' ,
     '  </template>' ,
     '</transform>'].join("");
    };
     
    //6) define the CONTROLLER methods
    widget.onclick = function(objEvent, objGUI) {
      //show random information
      alert(objEvent.clientX() + objGUI.id + WIDGET.XYZ + this.bg);
    };
     
    widget.setBG = function(strBG) {
      this.setProperty("bg",strBG);
    };
     
    widget.setText = function(strText) {
      this.setProperty("mytext",strText);
    };
     
});

Since:

3.6

Constructor Summary
void
init(strName : ?, vntLeft : ?, vntTop : ?, vntWidth : ?, vntHeight : ?)
instance initializer
Method Summary
void
clearBoxProfile(bRecurse : boolean)
Deletes the existing boxprofile for the object.
HTMLElement
getRenderedBox(strId : String, objRoot : HTMLElement)
Returns the HTML element (the view) corresponding to the box (model) defined by the uniqe identifier, strId
String | jsx3.xml.Document
Returns the XML template definition for the class.
void
Forces the template engine to recalculate the box profile for the instance.
void
setProperty(strName : String, strValue : String)
Sets a property on the instance.
void
setPropertyGUI(objGUI : HTMLElement, strName : String, strValue : String)
Similar to setProperty, except that the target GUI element can be specified as the first parameter.
void
syncProperty(strPropName : String | Array<String>, VIEW : Object, objGUI : HTMLElement)
Synchronize value(s) on the model to value(s) in the view (the view template).
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strName : ?, vntLeft : ?, vntTop : ?, vntWidth : ?, vntHeight : ?)
instance initializer

Parameters:

strName
vntLeft
vntTop
vntWidth
vntHeight
Method Detail

clearBoxProfile

void clearBoxProfile(bRecurse : boolean)
Deletes the existing boxprofile for the object. This is useful when a given template definition defines various (dynamic) DOMs. If a given value will result in the template needed to generate a different DOM, then this method should be called to ensure that the cached DOM is not used.

Parameters:

bRecurseif true, the profile for all descendants is also deleted. Typically, a left/top adjustment would pass false for this param, while all other adjustments that affect descendant structures would pass true.

getRenderedBox

HTMLElement getRenderedBox(strId : String, objRoot : HTMLElement)
Returns the HTML element (the view) corresponding to the box (model) defined by the uniqe identifier, strId

Parameters:

strIdID assigned to the box in the declarative markup
objRootThe root HTML element corresponding to the root box for the given GUI object instance; if not provided, this will be resolved via getRendered.

Returns:

 

getTemplateXML

String | jsx3.xml.Document getTemplateXML()
Returns the XML template definition for the class. When authoring your own GUI class, this method should return the XML for the transormation template.

Returns:

a string of XML or an instance of jsx3.xml.Document  

recalc

void recalc()
Forces the template engine to recalculate the box profile for the instance. This updates both the cached model and the on-scren view. Note that authoring a template with the attribute, recalc="true", will cause realc to be called each time the instance is painted. This means the following two template statements are equivalent:

<template recalc="true">...</template>
- or -
<template onpaint="this.recalc()">...</template>


setProperty

void setProperty(strName : String, strValue : String)
Sets a property on the instance. Triggers an update to synchronize model and view. This method may be called with a variable number of arguments, which are interpreted as name/value pairs, i.e.: obj.setProperty(n1, p1, n2, p2);. For example, the following two statements are equivalent:

obj.setProperty("jsxbgcolor","red");
obj.setBackgroundColor("red",true);

Parameters:

strNamethe name of the attribute.
strValuethe value of the attribute. If null, the attribute is removed.

setPropertyGUI

void setPropertyGUI(objGUI : HTMLElement, strName : String, strValue : String)
Similar to setProperty, except that the target GUI element can be specified as the first parameter. This is useful for repeated UI updates since it saves the system from resolving objGUI.

Parameters:

objGUIthe rendered native object.
strNamethe name of the attribute.
strValuethe value of the attribute. If null, the attribute is removed.

See Also:


syncProperty

void syncProperty(strPropName : String | Array<String>, VIEW : Object, objGUI : HTMLElement)
Synchronize value(s) on the model to value(s) in the view (the view template). Ensures a complete feedback loop from model to view. This method is different from setPropery in that setProperty is used to both update the model and view at the same time. For example, the following two examples are equivalent:

//example 1
obj.setProperty("jsxbgcolor","red");
 
//example 2
obj.jsxbgcolor = "red";
obj.syncProperty("jsxbgcolor");

Parameters:

strPropNameOne or more properties reflecting what was changed. For example, "jsxbgcolor" or ["jsxexecute","color"]
VIEWConfiguration object. Passing null is the same as passing true.

  • true Update the paintable model and then update the corresponding implementations of that property in the view
  • false Only update the paintable model. If any updates affect a box property (i.e., left, border, etc), the box profile will be set to 'dirty'.
  • {drawspace} Update the paintable model and then update the corresponding implementations of that property in the view. The object being passed will be used to seed any box updates. For example, passing {left:10}, would result in the box being moved to the pixel position, 10, regardless of what property updates get triggered.

objGUIOptional; if passed, this instance will be used; if not passed, objGUI will be resolved via [instance].getRendered()

See Also:


jsx3.gui

class TextBox

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.TextBox

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.gui.NumberInput

class TextBox
extends jsx3.gui.Block
This jsx3.gui.TextBox class allows integration of a standard HTML text input into the JSX DOM. This allows the text box to be treated like a JSX object, including positioning, serialization, updates, and data mapping/binding, etc.

Field Summary
static String
CSS color property
static String
jsx30textbox
static String
as needed by content
static String
none
static String
persistent scrollbars
static int
password type 2
static int
texbox type 0
static int
text area type 1
static String
email
static String
letter
static String
none
static String
numbers only
static String
telephone
static String
us ssn
static String
uszip
static int
no wrap
static int
wrap text (default)
Constructor Summary
void
init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strValue : String, TYPE : String)
instance initializer
Method Summary
void
call to designate an error or alert the user's attention to the textbox on-screen.
boolean
Validates the text box against its validation type.
protected String
formatValue(value : Object)
Formats the value of this text box before displaying it in the onscreen input box.
String
Returns value of textbox object when it was first initialized.
int
if TYPE for the object is jsx3.gui.TextBox.TYPETEXT, and this returns a positive integer, the maxlen property for the textbox will be set to this value; returns null if no value found
int
Returns whether this text box is read only.
int
Returns the type of TextBox.
String
Returns the custom validation expression (a regular expression pattern to match).
String
Returns the ID (CONSTANT) for one of the pre-canned regular expression filters that can be used to validate the user's response.
String
logically tries to determine the value for the text box by 1) checking for value of on-screen VIEW; 2) checking for 'value' property for in-memory MODEL 3) checking getDefaultValue() for value when object was first initialized.
static String
Deprecated.
String
Returns the text-wrapping/ word-breaking property for object if object type is jsx3.gui.TextBox.TYPETEXTAREA.
String
Returns the DHTML, used for this object's on-screen view.
protected Object
parseValue(input : String)
Parses the value of the onscreen input box before it is used as the value of the text box.
jsx3.gui.TextBox
setDefaultValue(strValue : String)
set during object initialization; useful for tracking edits/updates to an object by doing a string comparison between getValue() and getDefaultValue(); returns a reference to self to facilitate method chaining
jsx3.gui.TextBox
setMaxLength(intMaxLength : int)
if TYPE for the object is jsx3.gui.TextBox.TYPETEXT, setting this to a positive integer affects the maxlen property for the textbox; returns a reference to self to facilitate method chaining
jsx3.gui.TextBox
setOverflow(OVERFLOW : String)
Sets the overflow property of this object, which defines how its on-screen view will behave when its contents are larger than its specified width and/or height.
void
setReadonly(val : int)
Sets whether this text box is read only.
jsx3.gui.TextBox
setType(TYPE : int)
Sets the type of jsx3.gui.TextBox returns a reference to self to facilitate method chaining
jsx3.gui.TextBox
setValidationExpression(strValidationExpression : String)
Sets the custom validation expression (a regular expression pattern to match).
jsx3.gui.TextBox
setValidationType(VALIDATIONTYPE : String)
when set, applies one of the pre-canned regular expression filters that can be used to validate the user's response; returns a reference to self to facilitate method chaining.
jsx3.gui.TextBox
setValue(strValue : String)
updates value property for both on-screen VIEW (if object is painted) and in-memory MODEL; returns a reference to self to facilitate method chaining
jsx3.gui.TextBox
setWrap(bWrap : boolean)
Sets the text-wrapping/ word-breaking property for object if object type is jsx3.gui.TextBox.TYPETEXTAREA.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
CSS color property

DEFAULTCLASSNAME

static String DEFAULTCLASSNAME
jsx30textbox

OVERFLOWAUTO

static String OVERFLOWAUTO
as needed by content

OVERFLOWNORMAL

static String OVERFLOWNORMAL
none

OVERFLOWSCROLL

static String OVERFLOWSCROLL
persistent scrollbars

TYPEPASSWORD

static final int TYPEPASSWORD
password type 2

TYPETEXT

static final int TYPETEXT
texbox type 0

TYPETEXTAREA

static final int TYPETEXTAREA
text area type 1

VALIDATIONEMAIL

static final String VALIDATIONEMAIL
email

VALIDATIONLETTER

static final String VALIDATIONLETTER
letter

VALIDATIONNONE

static final String VALIDATIONNONE
none

VALIDATIONNUMBER

static final String VALIDATIONNUMBER
numbers only

VALIDATIONPHONE

static final String VALIDATIONPHONE
telephone

VALIDATIONSSN

static final String VALIDATIONSSN
us ssn

VALIDATIONUSZIP

static final String VALIDATIONUSZIP
uszip

WRAPNO

static final int WRAPNO
no wrap

WRAPYES

static final int WRAPYES
wrap text (default)
Constructor Detail

init

void init(strName : String, vntLeft : int | String, vntTop : int | String, vntWidth : int | String, vntHeight : int | String, strValue : String, TYPE : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
vntLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntWidtheither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
vntHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
strValuethis value to appear in the textbox/textarea. This value will be set as the defaultValue for the text box when it is initialized; if edits are made by the user, these edits can be accessed via [object].getValue(); if the initial value is needed, use [object].getDefaultValue();
TYPEone of two valid types: jsx3.gui.TextBox.TYPETEXT, jsx3.gui.TextBox.TYPETEXTAREA. If null is passed, jsx3.gui.TextBox.DEFAULTTYPE is used
Method Detail

beep

void beep()
call to designate an error or alert the user's attention to the textbox on-screen. Causes the textbox to 'flash/blink'

doValidate

boolean doValidate()
Validates the text box against its validation type.

Note that for this text box to pass validation for a regular expression, re, the following expression must evaluate to true: this.getValue().search(re) == 0. String.search() may behave differently than RegExp.test(); consult the JavaScript documentation for more information.

Returns:

true if field contains a valid value given @VALIDATIONTYPE  

Overrides:


formatValue

protected String formatValue(value : Object)
Formats the value of this text box before displaying it in the onscreen input box. This implementation returns the value converted to a string. A null value returns the empty string.

Parameters:

value

Returns:

 

Since:

3.7

getDefaultValue

String getDefaultValue()
Returns value of textbox object when it was first initialized. Default: [empty string]

Returns:

default value for object  

getMaxLength

int getMaxLength()
if TYPE for the object is jsx3.gui.TextBox.TYPETEXT, and this returns a positive integer, the maxlen property for the textbox will be set to this value; returns null if no value found

Returns:

positive integer  

getReadonly

int getReadonly()
Returns whether this text box is read only.

Returns:

1 (true) or 0.  

getType

int getType()
Returns the type of TextBox. Default: jsx3.gui.TextBox.TYPETEXT

Returns:

one of: jsx3.gui.TextBox.TYPETEXT, jsx3.gui.TextBox.TYPETEXTAREA, jsx3.gui.TextBox.TYPEPASSWORD  

getValidationExpression

String getValidationExpression()
Returns the custom validation expression (a regular expression pattern to match). If this method returns a valid regular expression (as a string), it will be applied instead of the pre-canned regular expression. Default: null returned by the method, getValidationType; null is returned if the expression is not found

Returns:

valid regular expression such as ^\d{3}-\d{2}-\d{4}$  

getValidationType

String getValidationType()
Returns the ID (CONSTANT) for one of the pre-canned regular expression filters that can be used to validate the user's response. Default: jsx3.gui.TextBox.VALIDATIONNONE

Returns:

one of: jsx3.gui.TextBox.VALIDATIONNONE, jsx3.gui.TextBox.VALIDATIONSSN, jsx3.gui.TextBox.VALIDATIONPHONE, jsx3.gui.TextBox.VALIDATIONEMAIL, jsx3.gui.TextBox.VALIDATIONNUMBER, jsx3.gui.TextBox.VALIDATIONLETTER, jsx3.gui.TextBox.VALIDATIONUSZIP  

getValue

String getValue()
logically tries to determine the value for the text box by 1) checking for value of on-screen VIEW; 2) checking for 'value' property for in-memory MODEL 3) checking getDefaultValue() for value when object was first initialized. Default: [empty string]

Returns:

value for object  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getWrap

String getWrap()
Returns the text-wrapping/ word-breaking property for object if object type is jsx3.gui.TextBox.TYPETEXTAREA. Default: jsx3.gui.TextBox.WRAPYES

Returns:

one of: jsx3.gui.TextBox.WRAPYES jsx3.gui.TextBox.WRAPNO  

paint

String paint()
Returns the DHTML, used for this object's on-screen view.

Returns:

DHTML  

Overrides:


parseValue

protected Object parseValue(input : String)
Parses the value of the onscreen input box before it is used as the value of the text box. This implementation returns the input without transforming it.

Parameters:

input

Returns:

 

Since:

3.7

setDefaultValue

jsx3.gui.TextBox setDefaultValue(strValue : String)
set during object initialization; useful for tracking edits/updates to an object by doing a string comparison between getValue() and getDefaultValue(); returns a reference to self to facilitate method chaining

Parameters:

strValuedefault value for the textbox/textarea

Returns:

this object  

setMaxLength

jsx3.gui.TextBox setMaxLength(intMaxLength : int)
if TYPE for the object is jsx3.gui.TextBox.TYPETEXT, setting this to a positive integer affects the maxlen property for the textbox; returns a reference to self to facilitate method chaining

Parameters:

intMaxLengthpositive integer, maxlen for the number of characters accepted by the textbox

Returns:

this object  

setOverflow

jsx3.gui.TextBox setOverflow(OVERFLOW : String)
Sets the overflow property of this object, which defines how its on-screen view will behave when its contents are larger than its specified width and/or height. Overflow only applies to text boxes of type TYPETEXTAREA.

Parameters:

OVERFLOWOVERFLOWNORMAL, OVERFLOWAUTO, or OVERFLOWSCROLL.

Returns:

this object. 

Overrides:

See Also:

, ,

setReadonly

void setReadonly(val : int)
Sets whether this text box is read only.

Parameters:

val1 (true) or 0.

setType

jsx3.gui.TextBox setType(TYPE : int)
Sets the type of jsx3.gui.TextBox returns a reference to self to facilitate method chaining

Parameters:

TYPEone of: jsx3.gui.TextBox.TYPETEXT, jsx3.gui.TextBox.TYPETEXTAREA, jsx3.gui.TextBox.TYPEPASSWORD

Returns:

this object  

setValidationExpression

jsx3.gui.TextBox setValidationExpression(strValidationExpression : String)
Sets the custom validation expression (a regular expression pattern to match). returns a reference to self to facilitate method chaining.

Parameters:

strValidationExpressionvalid regular expression such as ^\d{3}-\d{2}-\d{4}$ If null is passed custom value is removed and [object].getValidationType() is used instead

Returns:

this object  

setValidationType

jsx3.gui.TextBox setValidationType(VALIDATIONTYPE : String)
when set, applies one of the pre-canned regular expression filters that can be used to validate the user's response; returns a reference to self to facilitate method chaining.

Parameters:

VALIDATIONTYPEone of: jsx3.gui.TextBox.VALIDATIONNONE, jsx3.gui.TextBox.VALIDATIONSSN, jsx3.gui.TextBox.VALIDATIONPHONE, jsx3.gui.TextBox.VALIDATIONEMAIL, jsx3.gui.TextBox.VALIDATIONNUMBER, jsx3.gui.TextBox.VALIDATIONLETTER, jsx3.gui.TextBox.VALIDATIONUSZIP

Returns:

this object  

setValue

jsx3.gui.TextBox setValue(strValue : String)
updates value property for both on-screen VIEW (if object is painted) and in-memory MODEL; returns a reference to self to facilitate method chaining

Parameters:

strValuevalue for the textbox/textarea

Returns:

this object  

Overrides:


setWrap

jsx3.gui.TextBox setWrap(bWrap : boolean)
Sets the text-wrapping/ word-breaking property for object if object type is jsx3.gui.TextBox.TYPETEXTAREA.

Parameters:

bWrapone of: jsx3.gui.TextBox.WRAPYES jsx3.gui.TextBox.WRAPNO

Returns:

this object.  

jsx3.gui

class TimePicker

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.TimePicker

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class TimePicker
extends jsx3.gui.Block
A form element that allows for the selection of an arbitrary time of day. This control always shows hour and minute values and can be configured to show second and millisecond values as well.

This control is localized. The separators between the time fields are controlled by the server locale. Additionally, whether a 24 hour clock is used is determined by the server locale, although this can be overridden per instance by setting the 24hour property explicitly.

Since:

3.2

See Also:

jsx3.gui.DatePicker,

Constructor Summary
void
init(strName : String, intLeft : int | String, intTop : int | String, intHeight : int | String)
The instance initializer.
Method Summary
int
Returns STATEVALID if this time picker is not required or if it is required and its value is not null, otherwise returns STATEINVALID.
Date
getDate(objDate : Date)
Returns a date with the time of day set to the value of this time picker.
int
Returns the hour (0-23) of the time value of this time picker.
int
Returns the millisecond (0-999) of the time value of this time picker.
int
Returns the minute (0-60) of the time value of this time picker.
int
Returns the second (0-60) of the time value of this time picker.
int
Returns whether this time picker shows the millisecond input field.
int
Returns whether this time picker shows the second input field.
String
Returns the value of this time picker as a formatted string matching the appearance of the control.
int
Returns whether this time picker displays with a 24-hour clock.
String
jsx3.gui.TimePicker
set24Hour(b24Hour : boolean)
Sets whether this time picker uses a 24-hour clock.
void
setDate(objDate : Date)
Sets the value of this time picker in local time.
jsx3.gui.TimePicker
setFontSize(intPixelSize : int)
Sets the CSS font-size for the object; returns reference to self to facilitate method chaining;
void
setHours(intHours : int)
Sets the hour value of this time picker.
void
setMilliseconds(intMillis : int)
Sets the millisecond value of this time picker.
void
setMinutes(intMinutes : int)
Sets the minute value of this time picker.
void
setSeconds(intSeconds : int)
Sets the second value of this time picker.
jsx3.gui.TimePicker
Sets whether this time picker shows the millisecond input field.
jsx3.gui.TimePicker
Sets whether this time picker shows the second input field.
jsx3.gui.TimePicker
setValue(vntValue : String | Date | int)
Sets the value of this time picker in local time.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strName : String, intLeft : int | String, intTop : int | String, intHeight : int | String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
intLefteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
intTopeither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
intHeighteither a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
Method Detail

doValidate

int doValidate()
Returns STATEVALID if this time picker is not required or if it is required and its value is not null, otherwise returns STATEINVALID.

Returns:

 

Overrides:

See Also:

,

getDate

Date getDate(objDate : Date)
Returns a date with the time of day set to the value of this time picker. This method either returns the objDate parameter with the time of day set in local time or, if objDate is not provided, it returns a new date (the current day) with the time of day set.

Parameters:

objDatethe date on which to set the time of day. This parameter is optional.

Returns:

 

getHours

int getHours()
Returns the hour (0-23) of the time value of this time picker.

Returns:

 

getMilliseconds

int getMilliseconds()
Returns the millisecond (0-999) of the time value of this time picker.

Returns:

 

getMinutes

int getMinutes()
Returns the minute (0-60) of the time value of this time picker.

Returns:

 

getSeconds

int getSeconds()
Returns the second (0-60) of the time value of this time picker.

Returns:

 

getShowMillis

int getShowMillis()
Returns whether this time picker shows the millisecond input field. The millisecond input field will only display if both this and showSeconds are true.

Returns:

0 or 1.  

getShowSeconds

int getShowSeconds()
Returns whether this time picker shows the second input field.

Returns:

0 or 1.  

getValue

String getValue()
Returns the value of this time picker as a formatted string matching the appearance of the control.

Returns:

 

Overrides:


is24Hour

int is24Hour()
Returns whether this time picker displays with a 24-hour clock. The default value depends on the default locale.

Returns:

0 or 1.  

paint

String paint()

Returns:

 

Overrides:


set24Hour

jsx3.gui.TimePicker set24Hour(b24Hour : boolean)
Sets whether this time picker uses a 24-hour clock.

Parameters:

b24Hourmay be null to use the locale default value.

Returns:

this object  

setDate

void setDate(objDate : Date)
Sets the value of this time picker in local time. This method updates the view immediately.

Parameters:

objDatethe date whose time of day information to use for setting the value of this time picker. If this parameter is null, the current time value is cleared.

setFontSize

jsx3.gui.TimePicker setFontSize(intPixelSize : int)
Sets the CSS font-size for the object; returns reference to self to facilitate method chaining;

Parameters:

intPixelSizefont-size (in pixels)

Returns:

this object  

Overrides:


setHours

void setHours(intHours : int)
Sets the hour value of this time picker. This method updates the view immediately.

Parameters:

intHours0-23.

setMilliseconds

void setMilliseconds(intMillis : int)
Sets the millisecond value of this time picker. This method updates the view immediately.

Parameters:

intMillis0-999.

setMinutes

void setMinutes(intMinutes : int)
Sets the minute value of this time picker. This method updates the view immediately.

Parameters:

intMinutes0-59.

setSeconds

void setSeconds(intSeconds : int)
Sets the second value of this time picker. This method updates the view immediately.

Parameters:

intSeconds0-59.

setShowMillis

jsx3.gui.TimePicker setShowMillis(bShow : boolean)
Sets whether this time picker shows the millisecond input field.

Parameters:

bShow

Returns:

this object  

setShowSeconds

jsx3.gui.TimePicker setShowSeconds(bShow : boolean)
Sets whether this time picker shows the second input field.

Parameters:

bShow

Returns:

this object  

setValue

jsx3.gui.TimePicker setValue(vntValue : String | Date | int)
Sets the value of this time picker in local time. This method updates the view immediately.

Parameters:

vntValuethe date whose time of day information to use for setting the value of this time picker. This parameter may be a number, in which case it is taken as epoch seconds. It may also be a string, in which case it is parsed as the time portion of a date with the built-in JavaScript data parsing.

Returns:

this object  

Overrides:


jsx3.gui

class ToolbarButton

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.ToolbarButton

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher

class ToolbarButton
extends jsx3.gui.Block
Renders a toolbar button. Normal, check, and radio type buttons are supported. All buttons support 16x16 pixel icons. When rendered, buttons are 22 pixels wide by 22 pixels high (unless a text label is used or a menu is bound, in which case the button is wider).

This class publishes the following model events:

Field Summary
static int
Value of the state field indicating the up/off state.
static int
Value of the state field indicating the down/on state.
static int
Value of the type field indicating a check button.
static int
Value of the type field indicating a normal (stateless) button.
static int
Value of the type field indicating a radio button.
Constructor Summary
void
init(strName : String, intType : int, strTip : String)
The instance initializer.
Method Summary
void
Deprecated. Use doExecute() to invoke the EXECUTE model event programmatically.
void
Invokes the EXECUTE model event of this toolbar button.
int
Validates this button based on the type of button and whether this control is required.
String
Returns the URL of the image to use when this button is disabled.
int
Returns whether this toolbar button renders a visual divider on its left side.
String
Returns the name of the group to which this radio button belongs.
String
Returns the URL of the image to use to render this button.
int
Returns the state of this button.
int
Returns the type of this button.
static String
Deprecated.
String
Returns this toolbar button serialized to HTML.
jsx3.gui.ToolbarButton
Sets the URL of the image to use when this button is disabled.
jsx3.gui.ToolbarButton
setDivider(intDivider : int, bRecalc : ?)
Sets whether this toolbar button renders a visual divider on its left side.
jsx3.gui.ToolbarButton
setGroupName(strGroupName : String)
Sets the name of the group to which this radio button belongs.
jsx3.gui.ToolbarButton
setImage(strURL : String)
Sets the URL of the image to use to render this button.
jsx3.gui.ToolbarButton
setState(intState : int)
Sets the state of this button.
jsx3.gui.ToolbarButton
setType(TYPE : int)
Sets the type of this button.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, getValue, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState, setValue
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

STATEOFF

static final int STATEOFF
Value of the state field indicating the up/off state. A normal button is always off.

STATEON

static final int STATEON
Value of the state field indicating the down/on state. Check and radio buttons may be on.

TYPECHECK

static final int TYPECHECK
Value of the type field indicating a check button. A check button is a two-state button with a down state (on) and an up state (off).

TYPENORMAL

static final int TYPENORMAL
Value of the type field indicating a normal (stateless) button.

TYPERADIO

static final int TYPERADIO
Value of the type field indicating a radio button. A radio button is a two-state button that exists as a member of a set of radio buttons. Only one radio button is a set may be in a down state at one time.
Constructor Detail

init

void init(strName : String, intType : int, strTip : String)
The instance initializer.

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
intTypethe type of button to create: TYPENORMAL, or TYPECHECK, TYPERADIO.
strTipthe tooltip text for the button.
Method Detail

doClick

void doClick()
Deprecated. Use doExecute() to invoke the EXECUTE model event programmatically.
Invokes the EXECUTE model event of this toolbar button.

See Also:


doExecute

void doExecute(objEvent : jsx3.gui.Event)
Invokes the EXECUTE model event of this toolbar button. Note that because the model event is invoked programmatically rather than by user interaction the objEVENT event parameter will be null if the objEvent parameter is undefined. If this is a radio button its state is set to on. If this is a check button, its state is toggled.

Parameters:

objEventthe browser event that caused the execution of this button. This argument is optional and should only be provided if the execution of this button is the result of a browser event. This parameter will be passed along to the model event as objEVENT.

doValidate

int doValidate()
Validates this button based on the type of button and whether this control is required. Normal buttons are always valid because they have no state. Radio and check buttons are valid if they are on or if they are not required.

Returns:

jsx3.gui.Form.STATEVALID or jsx3.gui.Form.STATEINVALID

Overrides:

See Also:

,

getDisabledImage

String getDisabledImage()
Returns the URL of the image to use when this button is disabled.

Returns:

 

getDivider

int getDivider()
Returns whether this toolbar button renders a visual divider on its left side.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

getGroupName

String getGroupName()
Returns the name of the group to which this radio button belongs. This method returns null if this button is not a radio button.

Returns:

 

See Also:


getImage

String getImage()
Returns the URL of the image to use to render this button.

Returns:

 

getState

int getState()
Returns the state of this button. A normal button always returns STATEOFF. Radio and check buttons may return STATEOFF or STATEON.

Returns:

STATEON or STATEOFF

See Also:

,

getType

int getType()
Returns the type of this button.

Returns:

TYPENORMAL, or TYPECHECK, or TYPERADIO.  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns this toolbar button serialized to HTML.

Returns:

 

Overrides:


setDisabledImage

jsx3.gui.ToolbarButton setDisabledImage(strURL : String)
Sets the URL of the image to use when this button is disabled. If no disabled image is set the normal image is used instead.

Parameters:

strURLthe URL of an image file, 16px by 16px.

Returns:

this object.  

setDivider

jsx3.gui.ToolbarButton setDivider(intDivider : int, bRecalc : ?)
Sets whether this toolbar button renders a visual divider on its left side. The divider is useful for visually separating this toolbar button from the next toolbar button to the left.

Parameters:

intDividerjsx3.Boolean.TRUE or jsx3.Boolean.FALSE.
bRecalc

Returns:

this object.  

setGroupName

jsx3.gui.ToolbarButton setGroupName(strGroupName : String)
Sets the name of the group to which this radio button belongs. This method only applies to radio buttons.

Parameters:

strGroupNamethe name of button group.

Returns:

this object. 

See Also:


setImage

jsx3.gui.ToolbarButton setImage(strURL : String)
Sets the URL of the image to use to render this button. The URL is resolved by the URI resolver of this button before it is rendered to HTML.

Parameters:

strURLthe URL of an image file, 16px by 16px.

Returns:

this object.  

setState

jsx3.gui.ToolbarButton setState(intState : int)
Sets the state of this button. This method effects both the model and the view immediately. This method invokes the CHANGE model event only under the deprecated 3.0 model event protocol.

Parameters:

intStateSTATEON or STATEOFF.

Returns:

this object. 

See Also:

,

setType

jsx3.gui.ToolbarButton setType(TYPE : int)
Sets the type of this button.

Parameters:

TYPETYPENORMAL, or TYPECHECK, TYPERADIO.

Returns:

this object. 

See Also:

, ,

jsx3.gui

class Tree

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.Tree

All Implemented Interfaces:

jsx3.gui.Form, jsx3.gui.Interactive, jsx3.util.EventDispatcher, jsx3.xml.CDF, jsx3.xml.Cacheable

class Tree
extends jsx3.gui.Block
Creates a DHTML-based navigational trees (similar to the tree structure used by Windows Explorer with folders and files). This class expects XML source adhering to standards for version 3.0, the Common Data Format.

The Tree class by default supports the following CDF attributes: This class publishes the following model events:

Field Summary
static String
jsx:///images/matrix/append.gif
static String
Deprecated. Use CSS instead.
static String
#ffffff (default)
static String
  (default)
static String
Deprecated.
static String
static String
JSX/images/tree/file.gif (default)
static String
JSX/images/tree/minus.gif (default)
static String
JSX/images/tree/plus.gif (default)
static String
jsx:///images/matrix/insert_before.gif
static int
Enum value for the multiSelect property indicating a multi-select tree.
static String
Deprecated.
static String
JSX/images/tree/select.gif (default)
static int
Enum value for the multiSelect property indicating a single-select tree.
Constructor Summary
void
init(strName : String, strId : String)
instance initializer
Method Summary
int
validates the Tree; if the Tree is set to 'required', a selection must be made to pass validation.
void
executeRecord(strRecordId : String)
Executes any bound code for the record with id strRecordId.
String
Returns the Icon to use for items in the tree.
String
Returns the Icon to use when a node is in an open state.
String
Returns the Icon to use when the given tree node is in an closed state.
int
Deprecated. Key navigation now works with sorted trees.
int
Returns whether this tree is multi- (Tree.MULTI) or single-select (Tree.SINGLE).
String
Returns the text/HTML to display on-screen when the xml/xsl transformation for this object results in a null or empty result set
int
Returns whether or not the tree should paint its root node or paint the direct child nodes to the VIEW without rendering their containing root.
String
Deprecated.
String | Array<String>
Returns the jsxid attribute for the selected CDF record/records.
static String
Deprecated.
jsx3.xml.Document
Returns XSLT for the Tree, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.Tree
redrawRecord(strRecordId : String, ACTION : int)
if @strRecordId equals the id of the selected option (this.getValue()), only the text property will update; returns a ref to self to facilitate method chaining
void
revealRecord(strRecordId : String, objJSX : jsx3.gui.Block)
Reveals a record by toggling parent nodes as necessary and scrolling any containing blocks within the tree.
jsx3.gui.Tree
setIcon(strURL : String)
Sets the Icon to use for items in the tree; returns a ref to self
jsx3.gui.Tree
setIconMinus(strURL : String)
Sets the Icon to use when a node is in an open state.
jsx3.gui.Tree
setIconPlus(strURL : String)
Sets the Icon to use when the given tree node is in an closed state
jsx3.gui.Tree
setKeyListener(bBoolean : int)
Deprecated. Key navigation now works with sorted trees.
jsx3.gui.Tree
setMultiSelect(intMulti : int)
Sets whether this tree is multi- (Tree.MULTI) or single-select (Tree.SINGLE).
jsx3.gui.Tree
setRoot(bBoolean : int)
Sets whether or not the tree should paint its root node or paint the direct child nodes to the VIEW without rendering their containing root;
jsx3.gui.Tree
setValue(strRecordId : String | Array<String>, bReveal : boolean)
Selects a record in the tree.
jsx3.gui.Tree
toggleItem(strRecordId : String, bOpen : boolean)
toggles the open/closed state for a node on the tree; updates both MODEL and VIEW; if the tree is not yet painted and the open state for a node needs to be set, call: [tree instance].insertRecordProperty(@strId,@strPropName,@strPropValue,false); if there is a VIEW for the item, the 'ontoggle' event will be fired; if the developer has bound an ontoggle script (e.g.
Methods Inherited From jsx3.gui.Form
doKeyBinding, doReset, getDisabledBackgroundColor, getDisabledColor, getEnabled, getKeyBinding, getRequired, getValidationState, setDisabledBackgroundColor, setDisabledColor, setEnabled, setKeyBinding, setRequired, setValidationState
Methods Inherited From jsx3.xml.Cacheable
clearXmlData, getNodeSet, getShareResources, getXML, getXMLId, getXMLString, getXMLTransformers, getXMLURL, getXSLId, getXSLParams, getXSLString, getXSLURL, getXmlAsync, getXmlBind, onXmlBinding, removeXSLParam, removeXSLParams, resetCacheData, resetData, resetXmlCacheData, resetXslCacheData, setNodeSet, setShareResources, setSourceXML, setXMLId, setXMLString, setXMLTransformers, setXMLURL, setXSLId, setXSLParam, setXSLString, setXSLURL, setXmlAsync, setXmlBind
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

APPEND_IMG

static String APPEND_IMG
jsx:///images/matrix/append.gif

BORDERCOLOR

static String BORDERCOLOR
Deprecated. Use CSS instead.
#8CAEDF (default)

DEFAULTBACKGROUNDCOLOR

static String DEFAULTBACKGROUNDCOLOR
#ffffff (default)

DEFAULTNODATAMSG

static String DEFAULTNODATAMSG
&nbsp; (default)

DEFAULTXSLID

static String DEFAULTXSLID
Deprecated.
JSX_TREE_XSL (default)

DEFAULTXSLURL

static String DEFAULTXSLURL

ICON

static String ICON
JSX/images/tree/file.gif (default)

ICONMINUS

static String ICONMINUS
JSX/images/tree/minus.gif (default)

ICONPLUS

static String ICONPLUS
JSX/images/tree/plus.gif (default)

INSERT_BEFORE_IMG

static String INSERT_BEFORE_IMG
jsx:///images/matrix/insert_before.gif

MULTI

static final int MULTI
Enum value for the multiSelect property indicating a multi-select tree.

ONDROPBGIMAGE

static String ONDROPBGIMAGE
Deprecated.
url(JSX/images/tree/over.gif) (default)

SELECTEDIMAGE

static String SELECTEDIMAGE
JSX/images/tree/select.gif (default)

SINGLE

static final int SINGLE
Enum value for the multiSelect property indicating a single-select tree.
Constructor Detail

init

void init(strName : String, strId : String)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
strIdthis value should correspond to the jsxid for the 'record' node is the selected node for the tree
Method Detail

doValidate

int doValidate()
validates the Tree; if the Tree is set to 'required', a selection must be made to pass validation. Otherwise, a Tree will always pass validation

Returns:

one of: jsx3.gui.Form.STATEINVALID or jsx3.gui.Form.STATEVALID  

Overrides:


executeRecord

void executeRecord(strRecordId : String)
Executes any bound code for the record with id strRecordId. This method only invokes the EXECUTE model event for this tree under the deprecated 3.0 model event protocol.

Parameters:

strRecordIdjsxid value for the record node (according to the CDF) to execute

getIcon

String getIcon()
Returns the Icon to use for items in the tree. Default: jsx3.gui.Tree.ICON

Returns:

 

getIconMinus

String getIconMinus()
Returns the Icon to use when a node is in an open state. Default: jsx3.gui.Tree.ICONMINUS

Returns:

URL for icon to use when given tree node is toggled to closed; if null, value is reset to use URL referenced by jsx3.gui.Tree.ICONBOOKCLOSED  

getIconPlus

String getIconPlus()
Returns the Icon to use when the given tree node is in an closed state. Default: jsx3.gui.Tree.ICONPLUS

Returns:

URL for icon to use  

getKeyListener

int getKeyListener()
Deprecated. Key navigation now works with sorted trees.
Returns whether or not the tree will listen for key events. Typically this is set jsx3.Boolean.FALSE when the tree is sorted. Default: jsx3.Boolean.TRUE

Returns:

one of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE 

getMultiSelect

int getMultiSelect()
Returns whether this tree is multi- (Tree.MULTI) or single-select (Tree.SINGLE).

Returns:

 

Since:

3.1

See Also:

,

getNoDataMessage

String getNoDataMessage()
Returns the text/HTML to display on-screen when the xml/xsl transformation for this object results in a null or empty result set

Returns:

text/HTML  

getRoot

int getRoot()
Returns whether or not the tree should paint its root node or paint the direct child nodes to the VIEW without rendering their containing root. Default: jsx3.Boolean.TRUE

Returns:

one of jsx3.Boolean.TRUE or jsx3.Boolean.FALSE  

getText

String getText()
Deprecated.
if 'getValue()' returns a non-null, this method will return the corresponding jsxtext property in the CDF

Returns:

text or null 

Overrides:


getValue

String | Array<String> getValue()
Returns the jsxid attribute for the selected CDF record/records.

Returns:

if single-select the jsxid of the selected record or null if none selected; if multi-select an array of the selected record ids.  

Overrides:


getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getXSL

jsx3.xml.Document getXSL()
Returns XSLT for the Tree, prioritizing the acquisition in the following order: 1) check cache; 2) check jsxxsl; 3) check jsxxslurl; 4) use default

Returns:

jsx3.xml.Document instance containing valid XSL stylesheet  

Overrides:


paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


redrawRecord

jsx3.gui.Tree redrawRecord(strRecordId : String, ACTION : int)
if @strRecordId equals the id of the selected option (this.getValue()), only the text property will update; returns a ref to self to facilitate method chaining

Parameters:

strRecordIdid for the record that will be 'redrawn' on-screen
ACTIONOne of the following two values: jsx3.xml.CDF.INSERT, jsx3.xml.CDF.DELETE

Returns:

this object  

Overrides:


revealRecord

void revealRecord(strRecordId : String, objJSX : jsx3.gui.Block)
Reveals a record by toggling parent nodes as necessary and scrolling any containing blocks within the tree.

Parameters:

strRecordIdthe id of the record to reveal
objJSXif provided, reveal the record up to this visual block; useful if the tree is set to overflow:expand and the containing block is set to overflow:scroll.

setIcon

jsx3.gui.Tree setIcon(strURL : String)
Sets the Icon to use for items in the tree; returns a ref to self

Parameters:

strURLURL for icon to use

Returns:

this object  

setIconMinus

jsx3.gui.Tree setIconMinus(strURL : String)
Sets the Icon to use when a node is in an open state.

Parameters:

strURLURL for icon to use when given tree node is toggled to closed; if null, value is reset to use URL referenced by jsx3.gui.Tree.ICONBOOKCLOSED

Returns:

this object  

setIconPlus

jsx3.gui.Tree setIconPlus(strURL : String)
Sets the Icon to use when the given tree node is in an closed state

Parameters:

strURLURL for icon to use when given tree node is toggled to open; if null, value is reset to use URL referenced by jsx3.gui.Tree.ICONBOOKOPEN

Returns:

this object  

setKeyListener

jsx3.gui.Tree setKeyListener(bBoolean : int)
Deprecated. Key navigation now works with sorted trees.
Sets whether or not the tree will listen for key events. Typically this is set jsx3.Boolean.FALSE when the tree is sorted

Parameters:

bBooleanone of: jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object 

setMultiSelect

jsx3.gui.Tree setMultiSelect(intMulti : int)
Sets whether this tree is multi- (Tree.MULTI) or single-select (Tree.SINGLE).

Parameters:

intMultiTree.MULTI or Tree.SINGLE

Returns:

this object 

Since:

3.1

See Also:

,

setRoot

jsx3.gui.Tree setRoot(bBoolean : int)
Sets whether or not the tree should paint its root node or paint the direct child nodes to the VIEW without rendering their containing root;

Parameters:

bBooleanone of jsx3.Boolean.TRUE or jsx3.Boolean.FALSE

Returns:

this object  

setValue

jsx3.gui.Tree setValue(strRecordId : String | Array<String>, bReveal : boolean)
Selects a record in the tree. This method updates the model, datamodel, and view.

Parameters:

strRecordIdid for the record that will be the selected item, may be null to deselect all records
bReveal

Returns:

this object  

Overrides:


toggleItem

jsx3.gui.Tree toggleItem(strRecordId : String, bOpen : boolean)
toggles the open/closed state for a node on the tree; updates both MODEL and VIEW; if the tree is not yet painted and the open state for a node needs to be set, call: [tree instance].insertRecordProperty(@strId,@strPropName,@strPropValue,false); if there is a VIEW for the item, the 'ontoggle' event will be fired; if the developer has bound an ontoggle script (e.g., [treeinstance].setEvent("var a=1;",jsx3.gui.Interactive.TOGGLE);), this script will have contextual access to the variables: objGUI: object reference to the on-screen DHTML object for the node just toggled; objRECORD: object reference for the node in the XML Cache; strID: The jsxid property(as a string) for the node object; bOPEN: whether to item was toggled open (true) or closed (false). Returns a reference to self to facilitate method chaining

Parameters:

strRecordIdunique id for the given record (the 'jsxid' attribute on the given record node)
bOpenif null, the open state will be toggled; otherwise, true will expand the node to display its childre; false, vice versa

Returns:

this object  

jsx3.gui

class Window

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Window

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Window
extends jsx3.app.Model
Allows for rendering a branch of the DOM of an application in a separate browser window.

Access instances of this class with the following methods in the jsx3.app.Server class:

Since:

3.2

See Also:

, ,

Field Summary
static String
Event subject: published after this window has received focus.
static String
Event subject: published after this window has successfully opened.
static String
Event subject: published after this window has been resized via user interaction.
static String
Event subject: published after this window's parent has closed.
static String
Event subject: published just before this window will close.
Constructor Summary
void
init(strName : String)
The instance initializer.
Method Summary
boolean
Closes the browser window of this window instance.
void
Ensures that this window is at least partially visible on the computer screen.
void
Closes the native browser window bound to this window instance AND removes this instance and its descendants from the GI DOM.
void
Focuses the browser window of this window instance.
int
Returns the inner (visible) height of this window.
int
Returns the current x-coordinate screen position of this browser window relative to the parent application window.
int
Returns the current y-coordinate screen position of this browser window relative to the parent application window.
jsx3.gui.Block
Returns the first DOM child of this window object.
String
Returns the title of this window.
int
Returns the inner (visible) width of this window.
int
Returns whether this window is "dependent.
boolean
Returns whether the browser window of this window instance is open.
boolean
Returns whether the parent application window of this window instance is open.
int
Returns whether this window is resizable via user interaction.
int
Returns whether this window will show scroll bars if the content outgrows the window.
void
moveTo(intOffsetLeft : int, intOffsetTop : int)
Moves the browser window of this window instance to a position on the screen.
boolean
Opens the browser window of this window instance.
String
Repaints the root block of this window.
void
setDependent(bDependent : boolean)
Sets whether this window is "dependent.
void
setHeight(intHeight : int)
Sets the inner (visible) height of this window.
void
setResizable(bResizable : boolean)
Sets whether this window is resizable via user interaction.
void
setScrollable(bScrollable : boolean)
Sets whether this window will show scroll bars if the content outgrows the window.
void
setTitle(strTitle : String)
Sets the title of the window.
void
setWidth(intWidth : int)
Sets the inner (visible) width of this window.
String
toString(strTitle : ?)
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DID_FOCUS

static final String DID_FOCUS
Event subject: published after this window has received focus.

DID_OPEN

static final String DID_OPEN
Event subject: published after this window has successfully opened.

DID_RESIZE

static final String DID_RESIZE
Event subject: published after this window has been resized via user interaction.

PARENT_DID_CLOSE

static final String PARENT_DID_CLOSE
Event subject: published after this window's parent has closed.

WILL_CLOSE

static final String WILL_CLOSE
Event subject: published just before this window will close.
Constructor Detail

init

void init(strName : String)
The instance initializer.

Parameters:

strNamea unique name for this window.
Method Detail

close

boolean close()
Closes the browser window of this window instance. Call to properly close the window and perform all necessary resource cleanup. Note: due to differences across the various browsers, calling this method to close the browser window is preferable to allowing the user to close the window via the native browser close button in the window's caption bar.

Throws:

{jsx3.lang.Exception}if the window is already closed.

Returns:

true if the window successfully closed or false if it didn't close because of JavaScript security constraints or user interaction. 

constrainToScreen

void constrainToScreen()
Ensures that this window is at least partially visible on the computer screen.

doClose

void doClose()
Closes the native browser window bound to this window instance AND removes this instance and its descendants from the GI DOM. Note that this method will remove this instance and its descendants (the model), regardless of whether or not the browser window (the view) was able to be successfully closed. If you need greater control in case of errors affecting the native window, call close (e.g., this.close();), followed by a call to removeChild (e.g., this.getParent().removeChild(this);).

Since:

3.7

focus

void focus()
Focuses the browser window of this window instance.

Throws:

{jsx3.lang.Exception}if the window is not open.

getHeight

int getHeight()
Returns the inner (visible) height of this window. This does not include the border and padding that the browser may render around the window content.

Returns:

 

getOffsetLeft

int getOffsetLeft()
Returns the current x-coordinate screen position of this browser window relative to the parent application window. If the parent window is no longer open, this method returns the position relative to the upper-left corner of the screen.

Throws:

{jsx3.lang.Exception}if the window is not open.

Returns:

 

getOffsetTop

int getOffsetTop()
Returns the current y-coordinate screen position of this browser window relative to the parent application window. If the parent window is no longer open, this method returns the position relative to the upper-left corner of the screen.

Throws:

{jsx3.lang.Exception}if the window is not open.

Returns:

 

getRootBlock

jsx3.gui.Block getRootBlock()
Returns the first DOM child of this window object. If no child exists, this method creates a root block, adds it to the DOM, and returns it. A window will only render its first DOM child.

Returns:

 

getTitle

String getTitle()
Returns the title of this window.

Returns:

 

getWidth

int getWidth()
Returns the inner (visible) width of this window. This does not include the border and padding that the browser may render around the window content.

Returns:

 

isDependent

int isDependent()
Returns whether this window is "dependent." Dependent windows close automatically when their parents close. If a window is not dependent, it will stay open after the parent window closes. Note that the parent window contains all the JavaScript code and so it is very likely that interacting with a window after the parent has closed will raise errors.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

isOpen

boolean isOpen()
Returns whether the browser window of this window instance is open.

Returns:

true if the window is open.  

isParentOpen

boolean isParentOpen()
Returns whether the parent application window of this window instance is open.

Returns:

true if the parent window is open.  

isResizable

int isResizable()
Returns whether this window is resizable via user interaction. The value returned by this method will reflect the last value passed to setResizable() and therefore may not truly reflect the current state of the browser window.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

isScrollable

int isScrollable()
Returns whether this window will show scroll bars if the content outgrows the window. The value returned by this method will reflect the last value passed to setScrollable() and therefore may not truly reflect the current state of the browser window.

Returns:

jsx3.Boolean.TRUE or jsx3.Boolean.FALSE.  

moveTo

void moveTo(intOffsetLeft : int, intOffsetTop : int)
Moves the browser window of this window instance to a position on the screen. The arguments specify the offset from the parent application window. If the parent window is no longer open, this window will be moved relative to the upper-left corner of the screen.

Parameters:

intOffsetLeftthe left offset from the parent window.
intOffsetTopthe top offset from the parent window.

Throws:

{jsx3.lang.Exception}if the window is not open.

open

boolean open()
Opens the browser window of this window instance. Depending on security settings and popup blockers, this method may or may not actually open a window. The only safe way to determine whether the window successfully opened is to register for the DID_OPEN event.

Throws:

{jsx3.lang.Exception}if the window is already open.

Returns:

true if the window successfully opened (probably). 

repaint

String repaint()
Repaints the root block of this window.

Returns:

 

setDependent

void setDependent(bDependent : boolean)
Sets whether this window is "dependent." This method not affect a currently-open window.

Parameters:

bDependent

See Also:


setHeight

void setHeight(intHeight : int)
Sets the inner (visible) height of this window. If the window is currently open, the window will be resized immediately.

Parameters:

intHeightthe inner height of the window in pixels.

setResizable

void setResizable(bResizable : boolean)
Sets whether this window is resizable via user interaction. This method will not affect a currently-open window.

Parameters:

bResizable

setScrollable

void setScrollable(bScrollable : boolean)
Sets whether this window will show scroll bars if the content outgrows the window. This method will not affect a currently-open window.

Parameters:

bScrollable

setTitle

void setTitle(strTitle : String)
Sets the title of the window. The title is displayed in the title bar of the browser window. If the window is currently open, the title will be updated immediately.

Parameters:

strTitlethe title of the window.

setWidth

void setWidth(intWidth : int)
Sets the inner (visible) width of this window. If the window is currently open, the window will be resized immediately.

Parameters:

intWidththe inner width of the window in pixels.

toString

String toString(strTitle : ?)

Parameters:

strTitle

Returns:

 

Overrides:


jsx3.gui

class WindowBar

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.gui.WindowBar

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

class WindowBar
extends jsx3.gui.Block
jsx3.gui.WindowBar instances are used as the captionbar for JSXDialog and JSXAlert instances. They can contain any object type supported by the JSXBlock class. Developers will not instantiate this class (although it is possible); instead, when a new dialog is instanced, it will bind an instance of this class as a child for use as a captionbar container.

Field Summary
static String
The default background pattern
static String
#c8c8d5 (default)
static String
#ffffff (default)
static String
solid 1px #e8e8f5;solid 0px;solid 1px #a8a8b5;solid 0px; (default)
static String
solid 1px #9898a5;solid 1px #9898a5;solid 1px #9898a5;solid 1px #9898a5; (default)
static int
11 (default)
static String
jsx3.gui.Block.FONTBOLD (default)
static int
26 (default)
static int
0 (default)
static int
2
static int
3
static int
1
Constructor Summary
void
init(strName : String, TYPE : int)
instance initializer
Method Summary
int
Returns the type of the window bar; one of: jsx3.gui.WindowBar.TYPECAPTION, jsx3.gui.WindowBar.TYPETOOL, jsx3.gui.WindowBar.TYPEMENU, jsx3.gui.WindowBar.TYPETASK
static String
Deprecated.
String
Returns the DHTML, used for this object's on-screen VIEW
jsx3.gui.WindowBar
setText(strText : String, bRepaint : boolean)
calls super method in Block but if bRepaint is true, then also repaints task bar
jsx3.gui.WindowBar
setType(TYPE : int)
Returns the type of the window bar; returns reference to self to facilitate method chaining;
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

DEFAULTBACKGROUND

static String DEFAULTBACKGROUND
The default background pattern

DEFAULTBG

static String DEFAULTBG
#c8c8d5 (default)

DEFAULTBGCAPTION

static String DEFAULTBGCAPTION
#ffffff (default)

DEFAULTBORDER

static String DEFAULTBORDER
solid 1px #e8e8f5;solid 0px;solid 1px #a8a8b5;solid 0px; (default)

DEFAULTBORDERCAPTION

static String DEFAULTBORDERCAPTION
solid 1px #9898a5;solid 1px #9898a5;solid 1px #9898a5;solid 1px #9898a5; (default)

DEFAULTFONTSIZE

static int DEFAULTFONTSIZE
11 (default)

DEFAULTFONTWEIGHT

static String DEFAULTFONTWEIGHT
jsx3.gui.Block.FONTBOLD (default)

DEFAULTHEIGHT

static int DEFAULTHEIGHT
26 (default)

TYPECAPTION

static final int TYPECAPTION
0 (default)

TYPEMENU

static final int TYPEMENU
2

TYPETASK

static final int TYPETASK
3

TYPETOOL

static final int TYPETOOL
1
Constructor Detail

init

void init(strName : String, TYPE : int)
instance initializer

Parameters:

strNameunique name distinguishing this object from all other JSX GUI objects in the JSX application
TYPEone of: jsx3.gui.WindowBar.TYPECAPTION, jsx3.gui.WindowBar.TYPETOOL, jsx3.gui.WindowBar.TYPEMENU, jsx3.gui.WindowBar.TYPETASK
Method Detail

getType

int getType()
Returns the type of the window bar; one of: jsx3.gui.WindowBar.TYPECAPTION, jsx3.gui.WindowBar.TYPETOOL, jsx3.gui.WindowBar.TYPEMENU, jsx3.gui.WindowBar.TYPETASK

Returns:

one of: jsx3.gui.WindowBar.TYPECAPTION, jsx3.gui.WindowBar.TYPETOOL, jsx3.gui.WindowBar.TYPEMENU, jsx3.gui.WindowBar.TYPETASK  

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

paint

String paint()
Returns the DHTML, used for this object's on-screen VIEW

Returns:

DHTML  

Overrides:


setText

jsx3.gui.WindowBar setText(strText : String, bRepaint : boolean)
calls super method in Block but if bRepaint is true, then also repaints task bar

Parameters:

strTexttext/HTML
bRepaintif true, the view of this object is immediately updated, obviating the need to call repaint().

Returns:

 

Overrides:


setType

jsx3.gui.WindowBar setType(TYPE : int)
Returns the type of the window bar; returns reference to self to facilitate method chaining;

Parameters:

TYPEone of: jsx3.gui.WindowBar.TYPECAPTION, jsx3.gui.WindowBar.TYPETOOL, jsx3.gui.WindowBar.TYPEMENU, jsx3.gui.WindowBar.TYPETASK

Returns:

this object  

package jsx3.html

Utility methods related to rendering HTML.

Class Summary
jsx3.html.BlockTag
Represents an HTML element that occupies a rectangle of the screen.
jsx3.html.DOM
Handles Provides methods to manipulate browser DOM nodes.
jsx3.html.FontTag
Represents an HTML element that defines font styles.
jsx3.html.Style
Handles Provides methods to manipulate browser DOM nodes.
jsx3.html.Tag
Represents an HTML element.
jsx3.html.Text
Represents an HTML text node.
Method Summary
static void
copy(strText : String)
Copies the given string of text to the clipboard
static jsx3.app.Model
getJSXParent(objGUI : HTMLElement, objServer : jsx3.app.Server)
Traverses the browser DOM up from objGUI and returns the first GI DOM node that contains objGUI.
static void
getOuterHTML(objElement : HTMLElement)
Returns the serialized HTML representation of objElement.
static void
Pre-loads images into the HTML page so that they are available immediately when a control paints them.
static String
Returns the current text content of the clipboard
static void
setInnerText(objElement : HTMLElement, strText : String)
Replaces the children of objElement with a text node of value strText.
static void
setOuterHTML(objElement : HTMLElement, strHTML : String)
Replaces objElement with an HTML snippet, strHTML.
Method Detail

copy

static void copy(strText : String)
Copies the given string of text to the clipboard

Parameters:

strTexttext to copy

getJSXParent

static jsx3.app.Model getJSXParent(objGUI : HTMLElement, objServer : jsx3.app.Server)
Traverses the browser DOM up from objGUI and returns the first GI DOM node that contains objGUI.

Parameters:

objGUI
objServerif provided, only return a DOM node from this server.

Returns:

 

getOuterHTML

static void getOuterHTML(objElement : HTMLElement)
Returns the serialized HTML representation of objElement.

Parameters:

objElement

loadImages

static void loadImages(varImages : String... | jsx3.net.URI... | Array<String | jsx3.net.URI>)
Pre-loads images into the HTML page so that they are available immediately when a control paints them.

Parameters:

varImagesone or more relative URIs to image files. Each URI will be resolved against the default resolver.

paste

static String paste()
Returns the current text content of the clipboard

Returns:

 

setInnerText

static void setInnerText(objElement : HTMLElement, strText : String)
Replaces the children of objElement with a text node of value strText.

Parameters:

objElement
strText

setOuterHTML

static void setOuterHTML(objElement : HTMLElement, strHTML : String)
Replaces objElement with an HTML snippet, strHTML.

Parameters:

objElement
strHTML

jsx3.html

class BlockTag

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag

Direct Known Subclasses:

jsx3.vector.Canvas, jsx3.vector.Tag

class BlockTag
extends jsx3.html.Tag
Represents an HTML element that occupies a rectangle of the screen.

This class is available only when the Charting add-in is enabled.

Constructor Summary
void
init(strTagNS : String, strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
String
Returns the bgcolor field.
Array<int>
Returns the dimensions in an array of four int values
int
Returns the height field.
int
Returns the left field.
String
Returns the margin field, as set by setMargin().
Array
parses the margin field into an array of four int values
String
Returns the padding field, as set by setPadding().
Array
parses the padding field into an array of four int values
String
Returns the position field.
int
Returns the top field.
int
Returns the width field.
int
Returns the zIndex field.
void
Sets the bgcolor field.
void
setDimensions(left : int | Array<int>, top : int, width : int, height : int)
Sets all four dimensions at once.
void
setHeight(height : int)
Sets the height field.
void
setLeft(left : int)
Sets the left field.
void
setMargin(margin : String)
Sets the margin field, can be a single value or four values separated by space that correspond to top, right, bottom, and left.
void
setPadding(padding : String)
Sets the padding field, can be a single value or four values separated by space that correspond to top, right, bottom, and left.
void
setPosition(position : String)
Sets the position field, can be 'absolute' or 'relative'.
void
setTop(top : int)
Sets the top field.
void
setWidth(width : int)
Sets the width field.
void
setZIndex(zIndex : int)
Sets the zIndex field.
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strTagNS : String, strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

strTagNS
strTagName
leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

getBackgroundColor

String getBackgroundColor()
Returns the bgcolor field.

Returns:

bgcolor  

getDimensions

Array<int> getDimensions()
Returns the dimensions in an array of four int values

Returns:

[left,top,width,height]  

getHeight

int getHeight()
Returns the height field.

Returns:

height  

getLeft

int getLeft()
Returns the left field.

Returns:

left  

getMargin

String getMargin()
Returns the margin field, as set by setMargin().

Returns:

margin  

getMarginDimensions

Array getMarginDimensions()
parses the margin field into an array of four int values

Returns:

[top,right,bottom,left]  

getPadding

String getPadding()
Returns the padding field, as set by setPadding().

Returns:

padding  

getPaddingDimensions

Array getPaddingDimensions()
parses the padding field into an array of four int values

Returns:

[top,right,bottom,left]  

getPosition

String getPosition()
Returns the position field.

Returns:

position  

getTop

int getTop()
Returns the top field.

Returns:

top  

getWidth

int getWidth()
Returns the width field.

Returns:

width  

getZIndex

int getZIndex()
Returns the zIndex field.

Returns:

zIndex  

setBackgroundColor

void setBackgroundColor(bgcolor : String)
Sets the bgcolor field.

Parameters:

bgcolorthe new value for bgcolor

setDimensions

void setDimensions(left : int | Array<int>, top : int, width : int, height : int)
Sets all four dimensions at once.

Parameters:

leftthe new left value or an array containing all four new values
topthe new top value
widththe new width value
heightthe new height value

setHeight

void setHeight(height : int)
Sets the height field.

Parameters:

heightthe new value for height

setLeft

void setLeft(left : int)
Sets the left field.

Parameters:

leftthe new value for left

setMargin

void setMargin(margin : String)
Sets the margin field, can be a single value or four values separated by space that correspond to top, right, bottom, and left.

Parameters:

marginthe new value for margin

setPadding

void setPadding(padding : String)
Sets the padding field, can be a single value or four values separated by space that correspond to top, right, bottom, and left.

Parameters:

paddingthe new value for padding

setPosition

void setPosition(position : String)
Sets the position field, can be 'absolute' or 'relative'.

Parameters:

positionthe new value for position

setTop

void setTop(top : int)
Sets the top field.

Parameters:

topthe new value for top

setWidth

void setWidth(width : int)
Sets the width field.

Parameters:

widththe new value for width

setZIndex

void setZIndex(zIndex : int)
Sets the zIndex field.

Parameters:

zIndexthe new value for zIndex

jsx3.html

class DOM

Object
->jsx3.lang.Object
  ->jsx3.html.DOM

class DOM
extends jsx3.lang.Object
Handles Provides methods to manipulate browser DOM nodes.

Since:

3.6

Constructor Summary
void
instance initializer
Method Summary
static void
clearStyles(objNode : HTMLElement, strCSS : String)
Clears a string of multiple CSS style properties to a DOM element; Provides a way for a string of CSS to be removed from the node
static int
Gets the true offset height for the element including: margin, padding, border, and content
static int
Gets the true offset width for the element including: margin, padding, border, and content
static void
removeEventListener(objNode : HTMLElement, strName : String, objFn : Object)
Removes the function, objFn, as the event handler for the given DOM node.
static void
setStyle(objNode : HTMLElement, strCSSName : String, strValue : String)
Applies a single CSS style to a DOM node
static void
setStyles(objNode : HTMLElement, strCSS : String)
Applies a string of multiple CSS style properties to a DOM element
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init()
instance initializer
Method Detail

clearStyles

static void clearStyles(objNode : HTMLElement, strCSS : String)
Clears a string of multiple CSS style properties to a DOM element; Provides a way for a string of CSS to be removed from the node

Parameters:

objNodenative browser DOM node
strCSSstring of CSS. One of two variants are supported: left:10px;height:20px;width:100px; or left:;height:;width:;

getExtendedOffsetHeight

static int getExtendedOffsetHeight(objNode : HTMLElement)
Gets the true offset height for the element including: margin, padding, border, and content

Parameters:

objNodenative browser DOM node of type 'Element' that supports layout

Returns:

 

getExtendedOffsetWidth

static int getExtendedOffsetWidth(objNode : HTMLElement)
Gets the true offset width for the element including: margin, padding, border, and content

Parameters:

objNodenative browser DOM node of type 'Element' that supports layout

Returns:

 

removeEventListener

static void removeEventListener(objNode : HTMLElement, strName : String, objFn : Object)
Removes the function, objFn, as the event handler for the given DOM node.

Parameters:

objNodenative browser DOM node
strNameEvent name. For example, onclick, onfocus
objFnfunction, function literal

setStyle

static void setStyle(objNode : HTMLElement, strCSSName : String, strValue : String)
Applies a single CSS style to a DOM node

Parameters:

objNodenative browser DOM node
strCSSNameEither the CSS property name (i.e., background-color) or its scriptable property name (i.e., backgroundColor)
strValueFor example, red

setStyles

static void setStyles(objNode : HTMLElement, strCSS : String)
Applies a string of multiple CSS style properties to a DOM element

Parameters:

objNodenative browser DOM node
strCSSstring of CSS. For example, left:10px;height:20px;width:100px;

jsx3.html

interface FontTag

jsx3.html.FontTag

All Known Implementing Classes:

jsx3.vector.TextLine

interface FontTag
Represents an HTML element that defines font styles.

This class is available only when the Charting add-in is enabled.

Method Summary
String
Returns the color field.
String
Returns the fontFamily field.
String
Returns the fontsize field.
String
Returns the fontStyle field.
String
Returns the fontWeight field.
String
Returns the textAlign field.
String
Returns the textDecoration field.
void
setColor(color : String)
Sets the color field.
void
setFontFamily(fontFamily : String)
Sets the fontFamily field.
void
setFontSize(fontSize : int | String)
Sets the fontsize field.
void
setFontStyle(fontStyle : String)
Sets the fontStyle field.
void
setFontWeight(fontWeight : String)
Sets the fontWeight field.
void
setTextAlign(textAlign : String)
Sets the textAlign field.
void
setTextDecoration(textDecoration : String)
Sets the textDecoration field.
Method Detail

getColor

String getColor()
Returns the color field.

Returns:

color  

getFontFamily

String getFontFamily()
Returns the fontFamily field.

Returns:

fontFamily  

getFontSize

String getFontSize()
Returns the fontsize field.

Returns:

fontsize  

getFontStyle

String getFontStyle()
Returns the fontStyle field.

Returns:

fontStyle  

getFontWeight

String getFontWeight()
Returns the fontWeight field.

Returns:

fontWeight  

getTextAlign

String getTextAlign()
Returns the textAlign field.

Returns:

textAlign  

getTextDecoration

String getTextDecoration()
Returns the textDecoration field.

Returns:

textDecoration  

setColor

void setColor(color : String)
Sets the color field.

Parameters:

colorthe new value for color

setFontFamily

void setFontFamily(fontFamily : String)
Sets the fontFamily field.

Parameters:

fontFamilythe new value for fontFamily

setFontSize

void setFontSize(fontSize : int | String)
Sets the fontsize field.

Parameters:

fontSizethe new value for fontsize

setFontStyle

void setFontStyle(fontStyle : String)
Sets the fontStyle field.

Parameters:

fontStylethe new value for fontStyle

setFontWeight

void setFontWeight(fontWeight : String)
Sets the fontWeight field.

Parameters:

fontWeightthe new value for fontWeight

setTextAlign

void setTextAlign(textAlign : String)
Sets the textAlign field.

Parameters:

textAlignthe new value for textAlign

setTextDecoration

void setTextDecoration(textDecoration : String)
Sets the textDecoration field.

Parameters:

textDecorationthe new value for textDecoration

jsx3.html

class Style

Object
->jsx3.lang.Object
  ->jsx3.html.Style

class Style
extends jsx3.lang.Object
Handles Provides methods to manipulate browser DOM nodes.

Since:

3.6

Constructor Summary
void
instance initializer
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init()
instance initializer

jsx3.html

class Tag

Object
->jsx3.lang.Object
  ->jsx3.html.Tag

Direct Known Subclasses:

jsx3.html.BlockTag, jsx3.html.Text, jsx3.vector.Fill, jsx3.vector.Stroke

class Tag
extends jsx3.lang.Object
Represents an HTML element. Provides an object oriented way of painting to screen.

This class is available only when the Charting add-in is enabled.

Constructor Summary
void
init(strTagNS : String, strTagName : String)
The instance initializer.
Method Summary
void
Sdds a child to the list of this tag's children; may be vetoed by onAppendChild().
Array<jsx3.html.Tag>
Returns the children tags.
String
Returns the cssClass field.
String
Returns the cssClass field.
jsx3.html.Tag
Returns the first child tag of type type.
String
Returns the id field.
jsx3.html.Tag
Returns the parent tag.
String
getProperty(strName : String)
Returns an attribute of this HTML element.
String
getStyle(strName : String)
Returns a style of this HTML element.
String
Returns the namespace of this HTML element.
String
Returns the name of this HTML element, such as "table" or "div".
protected boolean
Called before appending a child.
protected boolean
Called before removing a child.
String
Serializes this HTML element to an HTML string using various overridable methods in this class.
HTMLElement
Prepares this HTML element for insertion into the live browser DOM and returns the underlying native HTML element.
protected void
This method is called on each HTML tag before it is painted to screen.
void
Releases all bi-directional references between this instance and its children.
void
Removes a child from the list of this tag's children; may be vetoed by onRemoveChild().
void
Removes all the children of this tag.
void
removeProperty(strName : String...)
Removes any number of properties from this HTML element.
void
removeStyle(strName : String...)
Removes any number of styles from this HTML element.
void
replaceChild(child : jsx3.html.Tag, oldChild : jsx3.html.Tag)
Replaces a child of this tag.
void
setClassName(cssClass : String)
Sets the cssClass field, the HTML 'class' attribute.
void
setClassName(cssClass : String)
Sets the cssClass field, the HTML 'class' attribute.
void
setExtraStyles(extraStyles : String)
Sets the extraStyles field, this string is prepended as-is to the generated value for the style attribute of the tag.
void
setId(id : String)
Sets the id field.
void
setProperty(strName : String, strValue : String)
Sets an attribute of this HTML element.
void
setStyle(strName : String, strValue : String)
Sets a style of this HTML element.
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strTagNS : String, strTagName : String)
The instance initializer.

Parameters:

strTagNS
strTagName
Method Detail

appendChild

void appendChild(child : jsx3.html.Tag)
Sdds a child to the list of this tag's children; may be vetoed by onAppendChild().

Parameters:

childthe child to add, must not already have a parent

getChildren

Array<jsx3.html.Tag> getChildren()
Returns the children tags.

Returns:

children  

getClassName

String getClassName()
Returns the cssClass field.

Returns:

cssClass  

getClassName

String getClassName()
Returns the cssClass field.

Returns:

cssClass  

getFirstChildOfType

jsx3.html.Tag getFirstChildOfType(type : String | Function)
Returns the first child tag of type type.

Parameters:

typethe fully-qualified class name or the class constructor function.

Returns:

 

getId

String getId()
Returns the id field.

Returns:

id  

getParent

jsx3.html.Tag getParent()
Returns the parent tag.

Returns:

parent  

getProperty

String getProperty(strName : String)
Returns an attribute of this HTML element.

Parameters:

strNamethe name of the attribute.

Returns:

the value of the attribute.  

getStyle

String getStyle(strName : String)
Returns a style of this HTML element.

Parameters:

strNamethe name of the style.

Returns:

the value of the style.  

getTagNS

String getTagNS()
Returns the namespace of this HTML element.

Returns:

the tag name  

getTagName

String getTagName()
Returns the name of this HTML element, such as "table" or "div".

Returns:

the tag name  

onAppendChild

protected boolean onAppendChild(child : jsx3.html.Tag)
Called before appending a child.

Parameters:

child

Returns:

true to allow the append, false to veto. 

onRemoveChild

protected boolean onRemoveChild(child : jsx3.html.Tag)
Called before removing a child.

Parameters:

child

Returns:

true to allow the removal, false to veto. 

paint

String paint()
Serializes this HTML element to an HTML string using various overridable methods in this class. This method is only available in the VML version of this class.

Returns:

this tag serialized to HTML.  

paintDom

HTMLElement paintDom()
Prepares this HTML element for insertion into the live browser DOM and returns the underlying native HTML element. This method is only available in the SVG version of this class.

Returns:

the native browser html element.  

paintUpdate

protected void paintUpdate()
This method is called on each HTML tag before it is painted to screen. Methods in subclasses of this class that override this method should begin with a call to jsxsuper().

release

void release()
Releases all bi-directional references between this instance and its children.

removeChild

void removeChild(child : jsx3.html.Tag)
Removes a child from the list of this tag's children; may be vetoed by onRemoveChild().

Parameters:

childthe child to remove, must exist in the list of children

removeChildren

void removeChildren()
Removes all the children of this tag.

removeProperty

void removeProperty(strName : String...)
Removes any number of properties from this HTML element.

Parameters:

strNamethe names of the attributes.

removeStyle

void removeStyle(strName : String...)
Removes any number of styles from this HTML element.

Parameters:

strNamethe names of the styles.

replaceChild

void replaceChild(child : jsx3.html.Tag, oldChild : jsx3.html.Tag)
Replaces a child of this tag.

Parameters:

childthe new child.
oldChildthe child to replace.

setClassName

void setClassName(cssClass : String)
Sets the cssClass field, the HTML 'class' attribute.

Parameters:

cssClassthe new value for cssClass

setClassName

void setClassName(cssClass : String)
Sets the cssClass field, the HTML 'class' attribute.

Parameters:

cssClassthe new value for cssClass

setExtraStyles

void setExtraStyles(extraStyles : String)
Sets the extraStyles field, this string is prepended as-is to the generated value for the style attribute of the tag.

Parameters:

extraStylesthe new value for extraStyles

setId

void setId(id : String)
Sets the id field.

Parameters:

idthe new value for id

setProperty

void setProperty(strName : String, strValue : String)
Sets an attribute of this HTML element. This method may be called with a variable number of arguments, which are interpreted as name/value pairs, i.e.: tag.setProperty(n1, p1, n2, p2);.

Parameters:

strNamethe name of the attribute.
strValuethe value of the attribute. If null, the attribute is removed.

setStyle

void setStyle(strName : String, strValue : String)
Sets a style of this HTML element. This method may be called with a variable number of arguments, which are interpreted as name/value pairs, i.e.: tag.setStyle(n1, s1, n2, s2);.

Parameters:

strNamethe name of the style.
strValuethe value of the style.

toString

String toString()

Returns:

 

Overrides:


jsx3.html

class Text

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.Text

class Text
extends jsx3.html.Tag
Represents an HTML text node.

This class is available only when the Charting add-in is enabled.

Constructor Summary
void
init(strText : String)
The instance initializer.
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strText : String)
The instance initializer.

Parameters:

strText

package jsx3.ide

The public API of the General Interface IDE. This package is only available when running in the IDE.

Field Summary
static jsx3.app.Server
The server instance corresponding to the application opened in the IDE.
Method Summary
static jsx3.app.Server
Returns the server instance corresponding to the currently active component editor tab.
static Array<jsx3.app.Model>
getSelected(bIncludeBody : boolean)
Returns the collection of DOM objects currently selected in the Component Hierarchy palette.
static void
loadTemplateCatalog(strType : String, strPath : String, objResolver : jsx3.net.URIResolver)
Loads a template catalog for the Properties Editor, Events Editor, or XSL Parameters palettes.
static void
registerTemplateForClass(strType : String, strClass : String, strPath : String | Function)
Registers a template for a particular class in the Properties Editor, Events Editor, or XSL Parameters palettes.
Field Detail

SERVER

static jsx3.app.Server SERVER
The server instance corresponding to the application opened in the IDE.
Method Detail

getActiveServer

static jsx3.app.Server getActiveServer()
Returns the server instance corresponding to the currently active component editor tab. If no tab is open or the active tab is not a component editor, this method returns null.

Returns:

 

getSelected

static Array<jsx3.app.Model> getSelected(bIncludeBody : boolean)
Returns the collection of DOM objects currently selected in the Component Hierarchy palette. Returns an empty array if that palette is closed.

Parameters:

bIncludeBody

Returns:

 

loadTemplateCatalog

static void loadTemplateCatalog(strType : String, strPath : String, objResolver : jsx3.net.URIResolver)
Loads a template catalog for the Properties Editor, Events Editor, or XSL Parameters palettes.

Parameters:

strTypeprop, event, or xsl.
strPaththe path to the catalog file.
objResolverthe object against which to resolve URIs contained in the catalog file.

See Also:


registerTemplateForClass

static void registerTemplateForClass(strType : String, strClass : String, strPath : String | Function)
Registers a template for a particular class in the Properties Editor, Events Editor, or XSL Parameters palettes.

Parameters:

strTypeprop, event, or xsl.
strClassthe fully-qualified class name.
strPaththe resolved path to the template file, or a function with signature function(objJSX : jsx3.app.Model) : jsx3.xml.Document

package jsx3.lang

Base classes and the GI introspection framework.

Note that all classes in this package are also accessible under the jsx3 namespace.

Class Summary
jsx3.lang.AOP
Simple aspect oriented programming for General Interface.
jsx3.lang.Class
JavaScript class that allows introspection of the JSX class hierarchy.
jsx3.lang.ClassLoader
The class loader initializes the system and loads applications and add-ins.
jsx3.lang.Exception
The base GI exception class.
jsx3.lang.IllegalArgumentException
A special exception type to throw when the caller of a function does not pass arguments according to the method's contract.
jsx3.lang.Method
JSX Class extends the build in JavaScript class Function.
jsx3.lang.NativeError
Wraps the browser-native exception object (what might be caught in a typical try/catch/finally block).
jsx3.lang.Object
Base class for all classes defined with jsx3.lang.Class.
jsx3.lang.Package
The Package class provides an introspectable API for JavaScript/JSX packages.
jsx3.lang.System
A collection of GI system related functions.
Method Summary
static Function
getCaller(intUp : int)
static Array<Function>
getStack(intUp : int)
Method Detail

getCaller

static Function getCaller(intUp : int)

Parameters:

intUp

Returns:

 

getStack

static Array<Function> getStack(intUp : int)

Parameters:

intUp

Returns:

 

jsx3.lang

class AOP

Object
->jsx3.lang.Object
  ->jsx3.lang.AOP

class AOP
extends jsx3.lang.Object
Simple aspect oriented programming for General Interface.

Advice can be added before, after, and around any call to an instance method of a GI class.

Note that only the exact class and subclasses loaded after a pointcut is defined are affected.

Note that only instance methods and not static methods can define pointcuts.

The second argument to the before, after, and around methods is the advice function, examples of which are provided here:
jsx3.AOP.pc("myPointcut", {classes:"jsx3.xml.Document", methods:"load"});
jsx3.AOP.before("myPointcut", function(strURL, intTimeout) {
  jsx3.log("load() called on " + this + " with URL " + strURL + ".");
});
jsx3.AOP.after("myPointcut", function(rv, strURL, intTimeout) {
  jsx3.log("load() called on " + this + " with URL " + strURL + " returned " + rv + ".");
});
jsx3.AOP.around("myPointcut", function(aop, strURL, intTimeout) {
  var t1 = new Date().getTime();
  var rv = aop.proceed(strURL, intTimeout);
  var tTotal = new Date().getTime() - t1;
  jsx3.log("load() called on " + this + " with URL " + strURL + " took " + tTotal + " ms and returned " + rv + ".");
  return rv;
});
Note that after advice receives the method return value as the first method parameter. Note also that around advice must manage the AOP chain by calling proceed() on the first method parameter and by returning the return value of this call.

Since:

3.6

Method Summary
static void
after(strPName : String, fctAdvice : Function, bRemove : boolean)
static void
around(strPName : String, fctAdvice : Function, bRemove : boolean)
static void
before(strPName : String, fctAdvice : Function, bRemove : boolean)
static void
pc(strName : String, objConditions : Object)
Creates a new pointcut.
static void
pcrem(strName : String)
Removes a pointcut.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

after

static void after(strPName : String, fctAdvice : Function, bRemove : boolean)

Parameters:

strPNamethe pointcut name.
fctAdvicethe advice function.
bRemoveif true, remove this advice.

around

static void around(strPName : String, fctAdvice : Function, bRemove : boolean)

Parameters:

strPNamethe pointcut name.
fctAdvicethe advice function.
bRemoveif true, remove this advice.

before

static void before(strPName : String, fctAdvice : Function, bRemove : boolean)

Parameters:

strPNamethe pointcut name.
fctAdvicethe advice function.
bRemoveif true, remove this advice.

pc

static void pc(strName : String, objConditions : Object)
Creates a new pointcut. The supported conditions are as follows:
  • classes {String|Function|jsx3.Class|Array<String|Function|jsx3.Class>}: the classes for which to look for methods.
  • methods {String|Array<String>}: the names of the methods for which to add pointcuts. Any name can be a regular expression with "*" expanded to \w+.
  • type: {String|Function|jsx3.Class}: the pointcut will only affect objects that are instanceOf(type).

Parameters:

strNamethe name of the pointcut to create.
objConditionsthe pointcut conditions.

pcrem

static void pcrem(strName : String)
Removes a pointcut.

Parameters:

strNamethe name of the pointcut to remove.

jsx3.lang

class Class

Object
->jsx3.lang.Object
  ->jsx3.lang.Class

class Class
extends jsx3.lang.Object
JavaScript class that allows introspection of the JSX class hierarchy.

You may obtain an instance of jsx3.lang.Class in one of the following ways: This class is also used for defining classes. Use one of defineClass and defineInterface to define a class in the JSX class hierarchy. Note that any class defined in the package jsx3.lang is aliased into the jsx3 package. Therefore jsx3.lang.Object may also be referenced as jsx3.Object.

The following are class nomenclature definitions using jsx3.lang.Object as an example:

The following is an example of how to define a new class called Example in package eg:
jsx3.lang.Class.defineClass(
  "eg.Example",                   // the full name of the class to create
  eg.Base,                        // the class extends eg.Base
  [eg.Comparable, eg.Testable],   // the class implements interfaces eg.Comparable and eg.Testable
  function(Example) {             // name the argument of this function "Example"
    
    // every class must define an init method since it is called automatically by the constructor
    Example.prototype.init = function(arg1) {
      this.arg1 = arg1;
    };
    // define an instance method like this:
    Example.prototype.instanceMethod = function() {
      ...
    };
    // define an abstract method like this:
    Example.prototype.abstractMethod = jsx3.Method.newAbstract();
    // define a static method like this:
    Example.staticMethod = function() {
      ...
    };
    // define a static field like this:
    Example.STATIC_FIELD = "...";
    // define an instance field like this:
    Example.prototype.instanceField = "...";
  }
);

Since:

3.1

See Also:

jsx3.lang.Object, jsx3.lang.Method, jsx3.lang.Package

Method Summary
void
addMethodMixin(strMethod : String, objClass : jsx3.lang.Class, strMixin : String)
Adds an after advice function to a method of this class via AOP.
jsx3.lang.Object
bless(obj : Object)
Creates a new instance of this class and populates its properties with the properties of the obj parameter.
static void
defineClass(strName : String, objExtends : Function | jsx3.lang.Class, arrImplements : Array<jsx3.lang.Class | Function | String>, fctBody : Function)
Defines a new class in the JSX hierarchy.
static void
defineInterface(strName : String, objExtends : Function | jsx3.lang.Class, fctBody : Function)
Defines a new interface in the JSX hierarchy.
static jsx3.lang.Class
forName(strName : String)
Retrieve an instance of jsx3.Class for a fully-qualified class name.
Array<jsx3.lang.Class>
Returns an array of all the classes defined in this class.
Function
Returns the constructor function of this class.
jsx3.lang.Method
getGetter(strProp : String)
Returns the accessor (getter) method of this class's bean property strProp.
Array<jsx3.lang.Class>
Returns the array of classes and interfaces that this class inherits from, ordered by precedence from highest to lowest.
Array<String>
Returns the array of instance fields defined for this class.
jsx3.lang.Method
getInstanceMethod(strMethodName : String)
Returns the instance method defined in this class with name strMethodName.
Array<jsx3.lang.Method>
Returns the array of instance methods defined for this class.
Array<jsx3.lang.Class>
Returns the array of interfaces that this class was defined to implement.
String
Returns the fully-qualified name of this class.
jsx3.lang.Package
Returns the package of this class.
String
Returns the package name of this class, e.g.
jsx3.lang.Method
getSetter(strProp : String)
Returns the mutator (setter) method of this class's bean property strProp.
Array<String>
Returns the array of static fields defined for this class.
jsx3.lang.Method
getStaticMethod(strMethodName : String)
Returns the static method defined in this class with name strMethodName.
Array<jsx3.lang.Method>
Returns the array of static methods defined for this class.
jsx3.lang.Class
Returns the super class of this class.
boolean
Determines whether this class is the same as or is a superclass or superinterface of parameter objClass.
boolean
Determines whether an object is an instance of this class.
boolean
Returns whether this class was defined as an interface.
void
mixin(obj : Object, bNoClobber : boolean, arrNames : Array<String>)
Copies all the instance methods in this class into an instance (of another class).
jsx3.lang.Object
newInnerClass(arg : Object...)
Creates a new instance of this class so that it can be used to create a java-style inner class extending this class.
Object
newInstance(arg : Object...)
Creates a new instance of this class by invoking the class constructor.
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

addMethodMixin

void addMethodMixin(strMethod : String, objClass : jsx3.lang.Class, strMixin : String)
Adds an after advice function to a method of this class via AOP. The pointcut is only active for instances of objClass.

Parameters:

strMethodthe name of the method of this class to which to add the advice.
objClassthe type condition for the pointcut.
strMixinthe name of the method to call from the advice function. This method is called on the the same instance of this class on which strMethod is called.

Since:

3.5

See Also:


bless

jsx3.lang.Object bless(obj : Object)
Creates a new instance of this class and populates its properties with the properties of the obj parameter. Does not call init() when instantiating the class.

Parameters:

objOptional parameter. If provided, this method will copy all the properties of obj into the newly created object.

Throws:

{jsx3.lang.Exception}if called on an instance of jsx3.lang.Class that represents an interface

Returns:

a new instance of this class 

defineClass

static void defineClass(strName : String, objExtends : Function | jsx3.lang.Class, arrImplements : Array<jsx3.lang.Class | Function | String>, fctBody : Function)
Defines a new class in the JSX hierarchy. After executing this method, an instance of jsx3.lang.Class representing the new class will be available for introspection.

Parameters:

strNamethe full name of the class to create, including the package prefix
objExtendsthe super class of the class to create; either the class constructor or the jsx3.Class instance itself. If no super class is provided, jsx3.Object will be used. May be null. If provided and representing an introspectable class, must be a class rather than an interface.
arrImplementsthe array of interfaces that the class to create will implement. Each item in the array may be either a class constructor, an instance of jsx3.Class, or a string but must represent an interface (a class created with defineInterface). May also be null or empty.
fctBodya function that defines the body of the class. This function takes two arguments, the constructor of the newly created interface, and its prototype. See class summary for more information.

defineInterface

static void defineInterface(strName : String, objExtends : Function | jsx3.lang.Class, fctBody : Function)
Defines a new interface in the JSX hierarchy. After executing this method, an instance of jsx3.lang.Class representing the new interface will be available for introspection.

Parameters:

strNamethe full name of the interface to create, including the package prefix
objExtendsthe super interface of the interface to create; either the class constructor or the jsx3.Class instance itself. If no super interface is provided, Object will be used. May be null. If provided and representing an introspectable class, must be an interface rather than a class.
fctBodya function that defines the body of the interface. This function takes two arguments, the constructor of the newly created interface, and its prototype. See class summary for more information.

forName

static jsx3.lang.Class forName(strName : String)
Retrieve an instance of jsx3.Class for a fully-qualified class name. This method will also return aliased classes such as jsx3.Object. Thus the name of the class returned by this method may not always equal the value of the strName parameter.

Parameters:

strNamethe fully-qualified (including package prefix) class name

Returns:

 

getClasses

Array<jsx3.lang.Class> getClasses()
Returns an array of all the classes defined in this class. This method returns the JSX equivalent of Java's public static inner classes.

To be returned by this method, a static inner class should be defined after the containing class is defined, like this:
jsx3.Class.defineClass("eg.ContainingClass", null, null, function(){});
jsx3.Class.defineClass("eg.ContainingClass.InnerClass", null, null, function(){});

Returns:

 

getConstructor

Function getConstructor()
Returns the constructor function of this class.

Returns:

 

getGetter

jsx3.lang.Method getGetter(strProp : String)
Returns the accessor (getter) method of this class's bean property strProp. Searches this class and the classes that it inherits method from for an instance method named "getStrProp" or "isStrProp" using the strProp parameter with the first letter made uppercase.

Parameters:

strPropthe name of the bean property whose getter to return

Returns:

the method or null if none found  

getInheritance

Array<jsx3.lang.Class> getInheritance()
Returns the array of classes and interfaces that this class inherits from, ordered by precedence from highest to lowest. This is the same order the defines where an inherited method will come from.

The order is:
  1. this class (not included in the returned array of this method)
  2. the interfaces that this class implements in the order that they were passed to the defineClass() function
  3. the superclass of this class ... recursively

Returns:

an array of jsx3.Class instances  

getInstanceFieldNames

Array<String> getInstanceFieldNames()
Returns the array of instance fields defined for this class.

Returns:

an array of String instances  

getInstanceMethod

jsx3.lang.Method getInstanceMethod(strMethodName : String)
Returns the instance method defined in this class with name strMethodName.

Parameters:

strMethodNamethe name of the method to find

Returns:

the method or null if none found matching strMethodName  

getInstanceMethods

Array<jsx3.lang.Method> getInstanceMethods()
Returns the array of instance methods defined for this class.

Returns:

an array of jsx3.lang.Method instances  

getInterfaces

Array<jsx3.lang.Class> getInterfaces()
Returns the array of interfaces that this class was defined to implement. This method does not return the interfaces that this class implements by way of its superclass.

Returns:

an array of jsx3.Class instances  

getName

String getName()
Returns the fully-qualified name of this class.

Returns:

 

getPackage

jsx3.lang.Package getPackage()
Returns the package of this class. This may be null if the namespace that this class was defined in was never initialized with jsx3.lang.Package.definePackage.

Returns:

 

getPackageName

String getPackageName()
Returns the package name of this class, e.g. jsx3.lang. If the package containing this class has been defined, then this method returns the name of the package. Otherwise, it returns the fully-qualified name of this class less the final token.

Returns:

 

getSetter

jsx3.lang.Method getSetter(strProp : String)
Returns the mutator (setter) method of this class's bean property strProp. Searches this class and the classes that it inherits method from for an instance method named "setStrProp" using the strProp parameter with the first letter made uppercase.

Parameters:

strPropthe name of the bean property whose setter to return

Returns:

the method or null if none found  

getStaticFieldNames

Array<String> getStaticFieldNames()
Returns the array of static fields defined for this class.

Returns:

an array of String instances  

getStaticMethod

jsx3.lang.Method getStaticMethod(strMethodName : String)
Returns the static method defined in this class with name strMethodName.

Parameters:

strMethodNamethe name of the method to find

Returns:

the method or null if none found matching strMethodName  

getStaticMethods

Array<jsx3.lang.Method> getStaticMethods()
Returns the array of static methods defined for this class.

Returns:

an array of jsx3.lang.Method instances  

getSuperClass

jsx3.lang.Class getSuperClass()
Returns the super class of this class. This will be null for an interface without a super interface or jsx3.lang.Object.

Returns:

null if no super class is defined  

isAssignableFrom

boolean isAssignableFrom(objClass : jsx3.lang.Class)
Determines whether this class is the same as or is a superclass or superinterface of parameter objClass.

Parameters:

objClassthe class to test

Returns:

 

isInstance

boolean isInstance(obj : Object)
Determines whether an object is an instance of this class.

Parameters:

objthe object to test

Throws:

{Error}if obj is null.

Returns:

 

isInterface

boolean isInterface()
Returns whether this class was defined as an interface.

Returns:

 

mixin

void mixin(obj : Object, bNoClobber : boolean, arrNames : Array<String>)
Copies all the instance methods in this class into an instance (of another class).

Parameters:

objthe target of the method transfer
bNoClobberif true, then do not transfer any methods already existing in obj
arrNames

newInnerClass

jsx3.lang.Object newInnerClass(arg : Object...)
Creates a new instance of this class so that it can be used to create a java-style inner class extending this class. This method will instantiate an interface or a class, in which case the init() method will be called. In this way you can accomplish the following:
var aClass = eg.Testable.jsxclass;       // get jsx3.lang.Class instance
var innerClass = aClass.newInnerClass(); // create inner class instance
innerClass.test = function() {};         // implement the eg.Testable interface
innerClass instanceof eg.Testable;       // evaluates to true

Parameters:

argarguments to pass to the constructor, supports up to 10 arguments

Returns:

a new instance of this class  

newInstance

Object newInstance(arg : Object...)
Creates a new instance of this class by invoking the class constructor. This is equivalent to calling new() on this class's constructor function and will call the class's init() method.

Parameters:

argthe variable number of arguments to send to the constructor

Returns:

 

toString

String toString()

Returns:

 

Overrides:


jsx3.lang

class ClassLoader

Object
->jsx3.lang.ClassLoader

All Implemented Interfaces:

jsx3.util.EventDispatcher

class ClassLoader
extends Object
The class loader initializes the system and loads applications and add-ins. One instance of this class (jsx3.CLASS_LOADER) is created when the system loads.

The following deployment parameters affect the behavior of the class loader:

See Also:

,

Field Summary
static int
static int
Method Summary
String
Returns the browser type as determined by the class loader.
jsx3.util.Job
jsx3.util.Job
loadApp(strAppPath : String, objGUI : HTMLElement, objEnv : Object<String, String>)
void
loadClass(strClass : String)
Loads a GI class synchronously.
boolean
Loads a JavaScript file synchronously.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From Object
toString
Field Detail

LOAD_ALWAYS

static final int LOAD_ALWAYS

LOAD_AUTO

static final int LOAD_AUTO
Method Detail

getType

String getType()
Returns the browser type as determined by the class loader. The possible return values are:
  • ie6 - Microsoft Internet Explorer versions 6.x
  • ie7 - Microsoft Internet Explorer versions 7.x
  • ie8 - Microsoft Internet Explorer versions 8.x
  • ie9 - Microsoft Internet Explorer all versions above 8.x
  • ie - Microsoft Internet Explorer earlier or unrecognized version
  • fx1_5 - Mozilla Firefox versions 1.5.x
  • fx2 - Mozilla Firefox versions 2.x
  • fx3 - Mozilla Firefox versions 3.x
  • fx4 - Mozilla Firefox all versions above 3.x
  • fx - Mozilla Firefox earlier or unrecognized version
  • sf3 - Apple Safari versions 3.x
  • sf4 - Apple Safari all versions above 3.x
  • sf - Apple Safari earlier or unrecognized version
  • gc1 - Google Chrome, any version
  • op9 - Opera versions 9.x
  • op10 - Opera all versions above 9.x
  • op - Opera earlier or unrecognized version
  • gk - other Gecko-based browser
  • xx - unrecognized browser

Returns:

 

loadAddin

jsx3.util.Job loadAddin(objAddin : String | jsx3.app.AddIn)

Parameters:

objAddin

Returns:

 

Since:

3.6

loadApp

jsx3.util.Job loadApp(strAppPath : String, objGUI : HTMLElement, objEnv : Object<String, String>)

Parameters:

strAppPath
objGUI
objEnv

Returns:

 

Since:

3.6

loadClass

void loadClass(strClass : String)
Loads a GI class synchronously. The location of the JavaScript file is determined by the classpath.

Parameters:

strClassthe fully-qualified name of the class to load.

Throws:

{jsx3.lang.Exception}if no registered classpath matched the class name or if the loaded JS file did not define the class to load.

Since:

3.5

loadJSFileSync

boolean loadJSFileSync(strURI : String)
Loads a JavaScript file synchronously.

Parameters:

strURI

Throws:

{Object}if evaluating the text content of the loaded file raises a JavaScript error.

Returns:

true if the file was loaded successfully. 

Since:

3.5

jsx3.lang

class Exception

Object
->jsx3.lang.Object
  ->jsx3.lang.Exception

Direct Known Subclasses:

jsx3.lang.IllegalArgumentException, jsx3.lang.NativeError

class Exception
extends jsx3.lang.Object
The base GI exception class.

Throwing an Exception

// throwing a simple exception:
throw new jsx3.Exception("an error occurred");

// throwing a nested exception:
try {
  ...
} catch (e) {
  throw new jsx3.Exception("an error occurred while ...", 
      jsx3.NativeError.wrap(e));
}

Catching an Exception

// catching an exception and logging it
try {
  ...
} catch (e) {
  jsx3.util.Logger.GLOBAL.error("an error occurred while ...", 
      jsx3.NativeError.wrap(e));
}

Since:

3.1

Constructor Summary
void
init(strMessage : String, objCause : jsx3.lang.Exception)
The instance initializer.
Method Summary
jsx3.lang.Exception
Returns the cause of this exception, if one was specified in the constructor.
String
Returns the description of this exception, as specified when the constructor was called.
Array<Function>
Returns the complete call stack from when this exception was instantiated as an array of functions.
String
Returns a string representation of the call stack for when this exception was instantiated.
String
Returns a string representation of this exception.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strMessage : String, objCause : jsx3.lang.Exception)
The instance initializer. A subclass of this class should always chain its init() method.

Parameters:

strMessagethe description of the exception.
objCausean optional argument. A caught exception that caused this exception to be raised.
Method Detail

getCause

jsx3.lang.Exception getCause()
Returns the cause of this exception, if one was specified in the constructor.

Returns:

 

getMessage

String getMessage()
Returns the description of this exception, as specified when the constructor was called.

Returns:

 

getStack

Array<Function> getStack()
Returns the complete call stack from when this exception was instantiated as an array of functions.

Returns:

 

printStackTrace

String printStackTrace()
Returns a string representation of the call stack for when this exception was instantiated. This stack trace is delimited by new line characters (\n) but is not terminated with one.

Returns:

 

toString

String toString()
Returns a string representation of this exception.

Returns:

 

Overrides:


jsx3.lang

class IllegalArgumentException

Object
->jsx3.lang.Object
  ->jsx3.lang.Exception
    ->jsx3.lang.IllegalArgumentException

class IllegalArgumentException
extends jsx3.lang.Exception
A special exception type to throw when the caller of a function does not pass arguments according to the method's contract.

Constructor Summary
void
init(strArg : String, objValue : Object)
The instance initializer.
Methods Inherited From jsx3.lang.Exception
getCause, getMessage, getStack, printStackTrace, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strArg : String, objValue : Object)
The instance initializer.

Parameters:

strArgthe name of the argument
objValuethe (illegal) value passed to the method

jsx3.lang

class Method

Object
->jsx3.lang.Object
  ->jsx3.lang.Method

class Method
extends jsx3.lang.Object
JSX Class extends the build in JavaScript class Function. Provides reflection capabilities.

Since:

3.1

Method Summary
Object | undefined
apply(thisArg : Object, argArray : Array)
Calls apply on the native function.
Object | undefined
call(arg : Object...)
Calls call on the native function.
int
Returns the number of parameters that this method takes (as declared in the JavaScript source).
jsx3.lang.Class | jsx3.lang.Package
Returns the class that defined this method.
Function
Returns the native JavaScript function of this method.
String
Returns the name of the method.
String
getParameterName(intIndex : int)
Returns the name of a parameter that this method takes (as declared in the JavaScript source).
Array<String>
Returns the names of parameters that this method takes (as declared in the JavaScript source).
boolean
Returns true if this method is abstract.
boolean
Returns whether the definer of this class (returned by getDeclaringClass()) is in fact a package.
boolean
Returns true if this method is static (is a class method).
static Function
newAbstract(paramNames : String...)
Creates a new abstract method.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

apply

Object | undefined apply(thisArg : Object, argArray : Array)
Calls apply on the native function.

Parameters:

thisArgthis argument to pass to Function.apply()
argArrayargument array to pass to Function.apply()

Returns:

 

call

Object | undefined call(arg : Object...)
Calls call on the native function.

Parameters:

argarguments to pass to Function.call(), supports up to 11 arguments (this+10)

Returns:

 

getArity

int getArity()
Returns the number of parameters that this method takes (as declared in the JavaScript source).

Returns:

 

getDeclaringClass

jsx3.lang.Class | jsx3.lang.Package getDeclaringClass()
Returns the class that defined this method.

Returns:

 

getFunction

Function getFunction()
Returns the native JavaScript function of this method.

Returns:

 

getName

String getName()
Returns the name of the method. The name of the method is determined when the class is defined.

Returns:

 

getParameterName

String getParameterName(intIndex : int)
Returns the name of a parameter that this method takes (as declared in the JavaScript source).

Parameters:

intIndexthe index of the parameter name to return

Returns:

 

getParameterNames

Array<String> getParameterNames()
Returns the names of parameters that this method takes (as declared in the JavaScript source).

Returns:

 

isAbstract

boolean isAbstract()
Returns true if this method is abstract. Abstract methods will throw an Exception if they are invoked.

Returns:

 

isPackageMethod

boolean isPackageMethod()
Returns whether the definer of this class (returned by getDeclaringClass()) is in fact a package.

Returns:

 

isStatic

boolean isStatic()
Returns true if this method is static (is a class method).

Returns:

 

newAbstract

static Function newAbstract(paramNames : String...)
Creates a new abstract method.

Parameters:

paramNamesthe names of the parameters that the abtract method will take

Throws:

{jsx3.lang.IllegalArgumentException}if any element in paramNames is not a valid JavaScript identifier.

Returns:

 

jsx3.lang

class NativeError

Object
->jsx3.lang.Object
  ->jsx3.lang.Exception
    ->jsx3.lang.NativeError

class NativeError
extends jsx3.lang.Exception
Wraps the browser-native exception object (what might be caught in a typical try/catch/finally block).

The following sample code shows how to use try/catch blocks in JavaScript and ensure that a caught exception is always an instance of jsx3.lang.Exception:
try {
  tryIt(); // code that may throw a native error (null-pointer, etc)
           // or an instance of jsx3.Exception
} catch (e) {
  e = jsx3.NativeError.wrap(e);
  // now e is guaranteed to be an instance of jsx3.Exception
  window.alert(e.printStackTrace());
}

Since:

3.1

Constructor Summary
void
init(objError : Object)
The instance initializer.
Method Summary
String
Returns the URL of the JavaScript include where this error was raised.
int
Returns the line number in the JavaScript include where this error was raised.
String
Returns the native message for this error.
String
Returns the native browser name for this error.
static void
Initializes the error trapping mechanism.
boolean
Deprecated.
String
Returns the native error as a human-readable string.
static jsx3.lang.Exception
Wraps a native browser exception in an instance of NativeError.
Methods Inherited From jsx3.lang.Exception
getCause, getStack, printStackTrace
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(objError : Object)
The instance initializer.

Parameters:

objErrorbrowser-native exception object (what would be thrown by a try/catch block)

Throws:

{jsx3.lang.IllegalArgumentException}if objException is not a native browser error. Use NativeError.wrap() if the type of caught object is unknown.

See Also:

Method Detail

getFileName

String getFileName()
Returns the URL of the JavaScript include where this error was raised.

Returns:

 

getLineNumber

int getLineNumber()
Returns the line number in the JavaScript include where this error was raised.

Returns:

 

getMessage

String getMessage()
Returns the native message for this error.

Returns:

 

Overrides:


getName

String getName()
Returns the native browser name for this error.

Returns:

 

initErrorCapture

static void initErrorCapture(fctTrap : Function)
Initializes the error trapping mechanism. Once this methor is called, all uncaught exceptions will be routed through this class to the logging system.

Parameters:

fctTrap

isStructural

boolean isStructural()
Deprecated.
Returns true if this error was due to poorly-formatted JavaScript (lexical/structural as opposed to logical).

Returns:

 

toString

String toString()
Returns the native error as a human-readable string.

Returns:

 

Overrides:


wrap

static jsx3.lang.Exception wrap(objError : jsx3.lang.Exception | Object)
Wraps a native browser exception in an instance of NativeError. This method also accepts an argument of type jsx3.Exception, in which case it will just return the argument. This method wraps any other type of argument by converting it to a string and and creating a new jsx3.Exception with that message.

Parameters:

objError

Returns:

 

jsx3.lang

class Object

Object
->jsx3.lang.Object

Direct Known Subclasses:

jsx3.EVT, jsx3.amp.Engine, jsx3.amp.Ext, jsx3.amp.ExtPoint, jsx3.amp.ExtProc, jsx3.amp.PlugIn, jsx3.amp.Resource, jsx3.amp.XML, jsx3.amp.util.MenuItem, jsx3.amp.util.MenuManager, jsx3.amp.util.Prefs, jsx3.amp.util.PrefsPane, jsx3.amp.util.ToolbarItem, jsx3.amp.util.ToolbarManager, jsx3.amp.util.Wizard, jsx3.amp.util.WizardPane, jsx3.app.AddIn, jsx3.app.Cache, jsx3.app.DOM, jsx3.app.Model, jsx3.app.Properties, jsx3.app.Server, jsx3.app.Settings, jsx3.app.UserSettings, jsx3.gui.Event, jsx3.gui.Heavyweight, jsx3.gui.HotKey, jsx3.gui.Matrix.ColumnFormat, jsx3.gui.Template, jsx3.html.DOM, jsx3.html.Style, jsx3.html.Tag, jsx3.lang.AOP, jsx3.lang.Class, jsx3.lang.Exception, jsx3.lang.Method, jsx3.lang.Package, jsx3.lang.System, jsx3.net.Form, jsx3.net.Request, jsx3.net.Service, jsx3.net.URI, jsx3.util.DateFormat, jsx3.util.Dojo, jsx3.util.List, jsx3.util.Locale, jsx3.util.Logger, jsx3.util.Logger.Handler, jsx3.util.Logger.Manager, jsx3.util.Logger.Record, jsx3.util.MessageFormat, jsx3.util.NumberFormat, jsx3.xml.DojoDataStore, jsx3.xml.Entity, jsx3.xml.Processor, jsx3.xml.Template

class Object
extends Object
Base class for all classes defined with jsx3.lang.Class.

Determining the Class of an Object

The class of an object can be determined in one of several ways.
  1. jsx3.lang.Object defines the method getClass(), which returns an instance of jsx3.lang.Class. This method is useful for testing whether an object is an instance of exactly (not a superclass of) a class.
  2. To test whether an object is an instance of a class or one of its superclasses, use the JavaScript operator instanceof: obj instanceof jsx3.lang.Object. Note that the right hand argument of this expression must be the constructor function of a class and not of an interface defined with jsx3.Class.defineInterface()).
  3. To test whether an object implements an interface, use the method instanceOf() defined in jsx3.lang.Object. This method will check against all classes and interfaces but is probably slower than the instanceof operator.
Examples:
var doc = new jsx3.gui.Block();
doc.getClass().equals(jsx3.gui.Block.jsxclass);  // true
doc.getClass().equals(jsx3.app.Model.jsxclass);  // false, even though Block extends Model
doc instanceof jsx3.gui.Block;  // true
doc instanceof jsx3.app.Model;  // true
doc instanceof jsx3.util.EventDispatcher;  // false, EventDispatcher is an interface
doc instanceof Object;          // true, works on non-jsx3.Class class constructors

doc.instanceOf(jsx3.gui.Block);            // true
doc.instanceOf(jsx3.app.Model.jsxclass);   // true, accepts arguments of type jsx3.Class
doc.instanceOf('jsx3.lang.Object');        // true, accepts arguments of type String
doc.instanceOf(jsx3.util.EventDispatcher); // true, works on interfaces
doc.instanceOf(Object);                    // true, works on non-jsx3.Class class constructors

Since:

3.1

Constructor Summary
void
Instance initializer.
Method Summary
jsx3.lang.Object
Returns a shallow copy of this object.
boolean
equals(obj : Object)
Returns true if this object is equals to the obj parameter.
Object
eval(strScript : String, objContext : Object)
Eval a string of code with a particular this and local variable stack context.
jsx3.lang.Class
Returns the class of this object.
String
Deprecated. use Object.getClass()
String
Deprecated. use Object.getClass().getName() and parse out final token
String
Deprecated. use Object.getClass().getPackageName()
boolean
Determines whether this object is an instance of objClass, that is, whether objClass is equal to or a superclass or superinterface of this object's class.
boolean
isInstanceOf(strClassName : String, strPropName : String, bIsRecurse : boolean)
Deprecated. use instanceof or Object.instanceOf()
boolean
isSubclassOf(strClassName : String)
Deprecated. no direct replacement
void
jsxmix(arg : Object...)
Deprecated. No-op, replaced with jsx3.lang.AOP.
protected Object | undefined
jsxsuper(arg : Object...)
Calls the supermethod overridden by the method that calls jsxsuper().
protected Object | undefined
jsxsupermix(arg : Object...)
Like jsxsuper() but traverses up through all the interfaces implemented by this class and its super classes.
void
setInstanceOf(strInstanceOf : String)
Deprecated. no direct replacement
String
Constructor Detail

init

void init()
Instance initializer.
Method Detail

clone

jsx3.lang.Object clone()
Returns a shallow copy of this object.

Returns:

 

equals

boolean equals(obj : Object)
Returns true if this object is equals to the obj parameter.

Parameters:

obj

Returns:

 

eval

Object eval(strScript : String, objContext : Object)
Eval a string of code with a particular this and local variable stack context.

Parameters:

strScriptthe code to execute
objContexta map containing the local variable stack context

Returns:

the eval value of the script  

getClass

jsx3.lang.Class getClass()
Returns the class of this object.

Returns:

 

getInstanceOf

String getInstanceOf()
Deprecated. use Object.getClass()
gets the class name for the object (the function that was instanced via 'new' to create the object). For example, jsx3.gui.Block, jsx3.gui.Tree, etc.

Returns:

class name of object 

getInstanceOfClass

String getInstanceOfClass()
Deprecated. use Object.getClass().getName() and parse out final token
gets the class name (less the package prefix) that this object is an instance of

Returns:

 

getInstanceOfPackage

String getInstanceOfPackage()
Deprecated. use Object.getClass().getPackageName()
returns the name of the package that this class belongs to; returns empty string if no package found

Returns:

 

instanceOf

boolean instanceOf(objClass : Function | jsx3.lang.Class | String)
Determines whether this object is an instance of objClass, that is, whether objClass is equal to or a superclass or superinterface of this object's class.

Parameters:

objClassthe class to test, may be either the class constructor, and instance of jsx3.lang.Class, or the fully-qualified class name

Throws:

{jsx3.lang.IllegalArgumentException}if objClass is a string that is not the name of a registered class

Returns:

 

isInstanceOf

boolean isInstanceOf(strClassName : String, strPropName : String, bIsRecurse : boolean)
Deprecated. use instanceof or Object.instanceOf()
returns whether or not this object is an instance of @strClassName

Parameters:

strClassNamenamed class
strPropNamedefault is INTERFACES; one of the strings: INTERFACES or SUPERS
bIsRecurseBRIDGE CODE; remove when old names fully deprecated/unsupported (release 4.0)

Returns:

 

isSubclassOf

boolean isSubclassOf(strClassName : String)
Deprecated. no direct replacement
Returns whether or not this object is an instance of a subclass of @strClassName

Parameters:

strClassNamenamed superclass

Returns:

 

jsxmix

void jsxmix(arg : Object...)
Deprecated. No-op, replaced with jsx3.lang.AOP.
No-op.

Parameters:

argthe variable number of arguments passed to the method mixins.

Since:

3.5

See Also:


jsxsuper

protected Object | undefined jsxsuper(arg : Object...)
Calls the supermethod overridden by the method that calls jsxsuper(). The following example shows a chained instance initializer method:
Subclass.prototype.init = function(a, b, c) {
  this.jsxsuper(a, b);  // calls the init() method in the superclass of Subclass
  this.c = c;
};

Parameters:

argthe variable number of arguments passed to the supermethod

Throws:

{jsx3.lang.Exception}if called by a static method, if called by a method not defined in a call to jsx3.lang.Class.defineClass()/defineInterface(), or if no suitable super method exists

Returns:

returns the result of the supermethod 

jsxsupermix

protected Object | undefined jsxsupermix(arg : Object...)
Like jsxsuper() but traverses up through all the interfaces implemented by this class and its super classes. This method facilitates modifying the functionality of a mixin interface for a particular class that implements the interface, as the following example shows:
// imagine that the jsx3.Testable mixin interface defines a method test() that provides basic testing functionality
jsx3.Class.defineClass('eg.Test', null, [jsx3.Testable], function(Test){
  Test.prototype.test = function() {
    this.setUpTest();      // do something before running the test
    this.jsxsupermix();    // calls test() in jsx3.Testable
    this.tearDownTest();   // do something after running the test
  };
});

Parameters:

argthe variable number of arguments passed to the supermethod

Throws:

{jsx3.lang.Exception}if called by a static method, if called by a method not defined in a call to jsx3.lang.Class.defineClass()/defineInterface(), or if no suitable super method exists

Returns:

returns the result of the supermethod 

setInstanceOf

void setInstanceOf(strInstanceOf : String)
Deprecated. no direct replacement
sets the JSX object type (only set during object initialization; although custom code can be written to 'cast' an object type to another object type)

Parameters:

strInstanceOftype of JSX object, such as jsx3.gui.Tree, jsx3.gui.Button, etc.

toString

String toString()

Returns:

a string representation of this object  

Overrides:


jsx3.lang

class Package

Object
->jsx3.lang.Object
  ->jsx3.lang.Package

class Package
extends jsx3.lang.Object
The Package class provides an introspectable API for JavaScript/JSX packages. It also provides a way of defining new packages.

An instance of this class may be obtained in one of the following ways (this class may not be instantiated directly): In this example, the JavaScript object jsx3.lang is known as the package "namespace," which is a plain JavaScript object and is analogous to the constructor property of a jsx3.Class.

The following is an example of how to define a new package called eg.tests:
jsx3.lang.Package.definePackage(
  "eg.tests",                           // the full name of the package to create
  function(tests) {                  // name the argument of this function "eg"
    
    // define a static method like this:
    tests.staticMethod = function() {
      ...
    };
    // define a static field like this:
    tests.STATIC_FIELD = "...";
  }
);

Since:

3.1

Method Summary
static void
definePackage(strName : String, fctBody : Function)
Defines a new package so that it is available for introspection.
static jsx3.lang.Package
forName(strName : String)
Returns the defined package with name equal to strName.
Array<jsx3.lang.Class>
Returns an array of all the classes defined in this package.
String
Returns the fully-qualified name of this class.
Object
Returns the namespace of this package.
static Array<jsx3.lang.Package>
Returns a list of all defined packages.
Array<String>
Returns the array of static fields defined for this package.
jsx3.lang.Method
getStaticMethod(strMethodName : String)
Returns the static method defined in this package with name strMethodName.
Array<jsx3.lang.Method>
Returns the array of static methods defined for this package.
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

definePackage

static void definePackage(strName : String, fctBody : Function)
Defines a new package so that it is available for introspection.

It is not an error if the namespace object already exists prior to calling this method. Any members defined by fctBody are simply added to the pre-existing namespace. Then, all members, whether defined before the call to this method or with the call to this method, are made introspectable.

This method may be called more than once with the same strName without causing an error. The package is simply redefined. Only the members that are defined in the namespace object after the last call to this method will be available for introspection.

It is an error if, after fctBody is executed, any two members of the namespace object equal the same function object. This is know as method aliasing, which can be a useful technique in JavaScript. Any method aliasing within the namespace object must occur after the call to this method. Therefore, method aliasing will cause an error if this package is redefined later.

Parameters:

strNamethe full package name
fctBodythe function that defines the body of the package. This function takes one argument which is the package "namespace".

forName

static jsx3.lang.Package forName(strName : String)
Returns the defined package with name equal to strName.

Parameters:

strNamethe full name of the package to retrieve

Returns:

the package or null if none matches  

getClasses

Array<jsx3.lang.Class> getClasses()
Returns an array of all the classes defined in this package.

Returns:

 

getName

String getName()
Returns the fully-qualified name of this class.

Returns:

 

getNamespace

Object getNamespace()
Returns the namespace of this package. The namespace is the JavaScript object, descending from window, that references this package by its property jsxpackage.

Returns:

 

getPackages

static Array<jsx3.lang.Package> getPackages()
Returns a list of all defined packages.

Returns:

 

getStaticFieldNames

Array<String> getStaticFieldNames()
Returns the array of static fields defined for this package.

Returns:

an array of String names  

getStaticMethod

jsx3.lang.Method getStaticMethod(strMethodName : String)
Returns the static method defined in this package with name strMethodName.

Parameters:

strMethodNamethe name of the method to find

Returns:

the method or null if none found matching strMethodName  

getStaticMethods

Array<jsx3.lang.Method> getStaticMethods()
Returns the array of static methods defined for this package.

Returns:

an array of jsx3.Method instances  

toString

String toString()

Returns:

 

Overrides:


jsx3.lang

class System

Object
->jsx3.lang.Object
  ->jsx3.lang.System

class System
extends jsx3.lang.Object
A collection of GI system related functions.

Method Summary
static void
If the locale has been explicitly set with setLocale(), that locale is returned.
static String
getMessage(strKey : String, strTokens : Object...)
static String
getProperty(strKey : String)
Returns a system property as specified by a JSS file loaded by the JSX runtime or an addin.
static String
Returns the version number of General Interface.
static void
static void
setLocale(objLocale : ?)
Sets the system-wide locale.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

getLocale

static void getLocale()
If the locale has been explicitly set with setLocale(), that locale is returned. Otherwise the locale is determined by introspecting the browser. If all else fails the default locale, en_US, is returned.

Since:

3.2

getMessage

static String getMessage(strKey : String, strTokens : Object...)

Parameters:

strKey
strTokens

Returns:

 

Since:

3.2

getProperty

static String getProperty(strKey : String)
Returns a system property as specified by a JSS file loaded by the JSX runtime or an addin.

Parameters:

strKey

Returns:

 

Since:

3.2

getVersion

static String getVersion()
Returns the version number of General Interface.

Returns:

"3.1.0", etc.  

reloadLocalizedResources

static void reloadLocalizedResources()

Since:

3.2

setLocale

static void setLocale(objLocale : ?)
Sets the system-wide locale. This in turn affects all applications running under the JSX system.

Parameters:

objLocale

Since:

3.2

package jsx3.net

Networking related classes.

Class Summary
jsx3.net.Form
Provides support for legacy HTML GET and POST forms.
jsx3.net.Request
A generic wrapper to hide the complexities and API-specifics of the native XMLHTTP control for a given browser.
jsx3.net.Service
This class is used in conjunction with the XML Mapping Utility to provide transactional support for those services using XML-based messaging.
jsx3.net.URI
Represents a Uniform Resource Identifier (URI) reference.
jsx3.net.URIResolver
An interface specifying the methods necessary to define a context against which URIs are resolved.

jsx3.net

class Form

Object
->jsx3.lang.Object
  ->jsx3.net.Form

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Form
extends jsx3.lang.Object
Provides support for legacy HTML GET and POST forms. Allows the submission of forms with arbitrary key-value pairs as well as file upload.

Prompting the user for a file upload field (promptForFile()) is only supported in Microsoft Internet Explorer.

Since:

3.0

Field Summary
static String
Event type published when a file has been chosen through user interaction.
static String
Event type published when a security error occurs trying to access the response.
static String
Event type published when the response has loaded.
static String
Event type published when the response is still not ready after the specified timeout period.
static String
static String
Constructor Summary
void
init(strMethod : String, strAction : String, bMultipart : boolean)
instance initializer
Method Summary
void
Stops polling for a response.
void
Adds a file upload field to this form.
void
Hides the IFRAME containing this form after it has been shown by calling reveal().
void
Destroys the form and the hidden IFRAME.
String
Returns the action of this form, the URL that this form is submitted to.
String
getField(strName : String)
Returns the value of a field in this form.
Array<String>
Returns the names of all fields in this form.
String
Returns the method of this form.
boolean
Returns whether this form is multipart.
String
Returns the content of the response as a string.
jsx3.xml.Document
Returns the content of the response as an XML document.
static jsx3.net.Form
newFromFragment(strFragment : String)
Creates a new form and initialize it from the HTML representation of a form.
void
promptForFile(strFieldName : String)
Invokes the operating system file browser to choose a file for a file upload field.
void
removeField(strName : String)
Removes a field from this form.
void
reveal(l : int, t : int, w : int, h : int)
Reveals the IFRAME containing this form for debugging purposes.
void
send(intPollInterval : int, intTimeout : int)
Sends the form.
void
setAction(action : String)
Sets the action of this form.
void
setField(strName : String, strValue : String, bConcat : boolean)
Sets the value of a field in this form.
void
setMethod(method : String)
Sets the method of this form.
void
setMultipart(multipart : boolean)
Sets whether this form is multipart.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

EVENT_FILE_SELECTED

static final String EVENT_FILE_SELECTED
Event type published when a file has been chosen through user interaction. The event has properties field and value.

EVENT_ON_ERROR

static final String EVENT_ON_ERROR
Event type published when a security error occurs trying to access the response.

EVENT_ON_RESPONSE

static final String EVENT_ON_RESPONSE
Event type published when the response has loaded.

EVENT_ON_TIMEOUT

static final String EVENT_ON_TIMEOUT
Event type published when the response is still not ready after the specified timeout period.

METHOD_GET

static final String METHOD_GET

METHOD_POST

static final String METHOD_POST
Constructor Detail

init

void init(strMethod : String, strAction : String, bMultipart : boolean)
instance initializer

Parameters:

strMethodform method, METHOD_GET (default) or METHOD_POST
strActionthe URL to submit to
bMultipartif true the form can support file upload
Method Detail

abort

void abort()
Stops polling for a response.

addFileUploadField

void addFileUploadField(strName : String)
Adds a file upload field to this form.

Parameters:

strNamethe name of the new field.

conceal

void conceal()
Hides the IFRAME containing this form after it has been shown by calling reveal().

Since:

3.2

See Also:


destroy

void destroy()
Destroys the form and the hidden IFRAME. This method should be called after receiving an onResponse, onError, or onTimeout event for proper garbage collection.

getAction

String getAction()
Returns the action of this form, the URL that this form is submitted to.

Returns:

action  

getField

String getField(strName : String)
Returns the value of a field in this form.

Parameters:

strNamethe name of the form field to query.

Returns:

the field value or null if no such field exists.  

getFields

Array<String> getFields()
Returns the names of all fields in this form.

Returns:

 

getMethod

String getMethod()
Returns the method of this form.

Returns:

METHOD_GET or METHOD_POST.  

getMultipart

boolean getMultipart()
Returns whether this form is multipart. Only multipart forms may upload files.

Returns:

 

getResponseText

String getResponseText()
Returns the content of the response as a string.

Returns:

 

getResponseXML

jsx3.xml.Document getResponseXML()
Returns the content of the response as an XML document.

Returns:

 

newFromFragment

static jsx3.net.Form newFromFragment(strFragment : String)
Creates a new form and initialize it from the HTML representation of a form.

Parameters:

strFragmentthe html fragment containing a
tag.

Throws:

an error if the fragment was not well-formed or did not contain a form tag.

Returns:

 

promptForFile

void promptForFile(strFieldName : String)
Invokes the operating system file browser to choose a file for a file upload field. This method is not supported in browsers other than Microsoft Internet Explorer.

Parameters:

strFieldNamethe name of the file upload field.

removeField

void removeField(strName : String)
Removes a field from this form.

Parameters:

strNamethe name of the form field to remove.

reveal

void reveal(l : int, t : int, w : int, h : int)
Reveals the IFRAME containing this form for debugging purposes. Dimensions of the revealed form may be provided or a default position and dimensions will be used.

Parameters:

lpixels from the left side of the HTML page that the IFRAME will be displayed.
tpixels from the top of the HTML page that the IFRAME will be displayed.
wwidth of the revealed IFRAME, in pixels.
hheight of the revealed IFRAME, in pixels.

Since:

3.2

See Also:


send

void send(intPollInterval : int, intTimeout : int)
Sends the form. Sending the form is always asynchronous. Once a form has been sent it may not be reused.

Parameters:

intPollIntervalmilliseconds between checking for a response. If not provided, the default value is 1/4 sec.
intTimeouttotal milliseconds before timeout. If not provided, the default value is 30 sec.

setAction

void setAction(action : String)
Sets the action of this form.

Parameters:

action

setField

void setField(strName : String, strValue : String, bConcat : boolean)
Sets the value of a field in this form. Line breaks and whitespace are honored although any line breaks will be converted to either \r\n or \n depending on the platform. Setting the value to null will set it to the empty string.

Parameters:

strNamethe name of the form field to set.
strValuethe new value of form field.
bConcatif true, will append " " + strValue to the existing value. The space is only inserted if the existing value is not empty.

setMethod

void setMethod(method : String)
Sets the method of this form.

Parameters:

methodMETHOD_GET or METHOD_POST.

setMultipart

void setMultipart(multipart : boolean)
Sets whether this form is multipart.

Parameters:

multipart

jsx3.net

class Request

Object
->jsx3.lang.Object
  ->jsx3.net.Request

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Request
extends jsx3.lang.Object
A generic wrapper to hide the complexities and API-specifics of the native XMLHTTP control for a given browser. Developers wishing to create/modify XML documents can use this class to access common XMLHTTP methods.

Note that when using this interface to post xml content to a server, the called server may expect the content type to be set for the posting. For example, objRequest.setRequestHeader("Content-Type", "text/xml");

Field Summary
static String
Event type published when the response has loaded.
static String
Event type published when the server has not responded after the specified timeout period.
Constructor Summary
void
init(id : String)
The instance initializer.
Method Summary
jsx3.net.Request
Aborts the request.
static void
addSchemeHandler(scheme : String, handler : jsx3.lang.Class)
Adds a handler that will field requests to a particular URL scheme.
static void
cancelRequest(strRequestId : String)
Deprecated. Use abort() instead.
String
Gets the value of all the HTTP headers.
XMLHttpRequest
Deprecated.
int
Deprecated. This method is not consistent between browsers. Use the event publisher interface instead to track the state of the request.
static jsx3.net.Request
getRequest(strRequestId : String)
Deprecated. Static access to pending requests by id is deprecated.
String
Gets the value of a specific HTTP response header.
String
Gets the content of the response as string.
jsx3.xml.Document
Gets the content of the response as an XML document.
int
Gets the HTTP response code (e.g.
String
Gets the HTTP response line status (e.g.
String
Gets the URL passed when opening this request.
static String
Deprecated.
static void
open(strMethod : ?, strURL : ?, bAsync : ?, strUser : ?, strPass : ?)
Creates and opens a request object.
jsx3.net.Request
open(strMethod : String, strURL : String | jsx3.net.URI, bAsync : boolean, strUser : String, strPass : String)
Initializes the request, and specifies the method, URL, and authentication information for the request.
jsx3.net.Request
send(strContent : String, intTimeout : int)
Sends the request.
jsx3.net.Request
setRequestHeader(strName : String, strValue : String)
Sets the value of a specific HTTP request header.
jsx3.net.Request
setTimeouts(intResolveTimeout : int, intConnectTimeout : int, intSendTimeout : int, intReceiveTimeout : int)
Deprecated. IE only.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

EVENT_ON_RESPONSE

static final String EVENT_ON_RESPONSE
Event type published when the response has loaded.

EVENT_ON_TIMEOUT

static final String EVENT_ON_TIMEOUT
Event type published when the server has not responded after the specified timeout period.
Constructor Detail

init

void init(id : String)
The instance initializer.

Parameters:

idIf the call will be asynchronous, assigns a unique identifier. Using this deprecated parameter will cause memory to leak. Don't use it.
Method Detail

abort

jsx3.net.Request abort()
Aborts the request.

Returns:

this object.  

addSchemeHandler

static void addSchemeHandler(scheme : String, handler : jsx3.lang.Class)
Adds a handler that will field requests to a particular URL scheme.

Parameters:

schemethe scheme that the handler to handle.
handlera custom subclass of Request.

Since:

3.7

cancelRequest

static void cancelRequest(strRequestId : String)
Deprecated. Use abort() instead.
Cancels the named request.

Parameters:

strRequestIdnamed id for the request (assigned by developer when the Request was instanced);

See Also:


getAllResponseHeaders

String getAllResponseHeaders()
Gets the value of all the HTTP headers.

Returns:

 

getNative

XMLHttpRequest getNative()
Deprecated.

Returns:

 

getReadyState

int getReadyState()
Deprecated. This method is not consistent between browsers. Use the event publisher interface instead to track the state of the request.
Gets the ready state for the request; return values include: 0) The object has been created, but not initialized (the open method has not been called). 1) The object has been created, but the send method has not been called. 2) The send method has been called, but the status and headers are not yet available. 3) Some data has been received. Calling the responseBody and responseText properties at this state to obtain partial results will return an error, because status and response headers are not fully available. 4) All the data has been received, and the complete data is available via the getResponseText()/getResponseXML() methods

Returns:

 

getRequest

static jsx3.net.Request getRequest(strRequestId : String)
Deprecated. Static access to pending requests by id is deprecated.
Gets the named request instance.

Parameters:

strRequestIdnamed id for the request (assigned by developer when the Request was instanced);

Returns:

 

getResponseHeader

String getResponseHeader(strName : String)
Gets the value of a specific HTTP response header.

Parameters:

strNamethe name for the response header to retrieve.

Returns:

 

getResponseText

String getResponseText()
Gets the content of the response as string.

Returns:

 

getResponseXML

jsx3.xml.Document getResponseXML()
Gets the content of the response as an XML document. If the response is not a valid XML document, null is returned.

Returns:

 

getStatus

int getStatus()
Gets the HTTP response code (e.g. 200, 404, 500, etc).

Returns:

 

getStatusText

String getStatusText()
Gets the HTTP response line status (e.g. "OK").

Returns:

 

getURL

String getURL()
Gets the URL passed when opening this request.

Returns:

 

getVersion

static String getVersion()
Deprecated.
gets the release/build for the class (i.e., "3.0.00")

Returns:

 

open

static void open(strMethod : ?, strURL : ?, bAsync : ?, strUser : ?, strPass : ?)
Creates and opens a request object. This is a factory method that creates the proper subclass of Request based on the scheme of strURL.

Parameters:

strMethod
strURL
bAsync
strUser
strPass

Since:

3.7

See Also:


open

jsx3.net.Request open(strMethod : String, strURL : String | jsx3.net.URI, bAsync : boolean, strUser : String, strPass : String)
Initializes the request, and specifies the method, URL, and authentication information for the request.

Parameters:

strMethodThe HTTP method used to open the connection. Valid values include: GET, POST, or PUT.
strURLThe requested URL. This can be either an absolute URL, such as "http://www.TIBCO.com", or a relative URL, such as "../MyPath/MyFile".
bAsyncwhether to issue the request asynchronously, if true this class will use the EventDispatcher interface to publish an event on response or timeout.
strUserThe name of the user for authentication. If this parameter is null ("") or missing and the site requires authentication, the native HTTP control will display a logon window.
strPassThe password for authentication. This parameter is ignored if the user parameter is null ("") or missing.

Returns:

this object.  

send

jsx3.net.Request send(strContent : String, intTimeout : int)
Sends the request.

Parameters:

strContentThe content to send for a POST request.
intTimeoutthe number milliseconds to wait before publishing a timeout event. This only applies to asynchronous requests. If used, subscribe to the jsx3.net.Request.EVENT_ON_TIMEOUT event to be notified of a timeout.

Returns:

this object.  

setRequestHeader

jsx3.net.Request setRequestHeader(strName : String, strValue : String)
Sets the value of a specific HTTP request header. The open() method should be called before calling this method.

Parameters:

strNamethe name for the request header to send to the server with the request content.
strValuethe value for the request header to send to the server with the request content.

Returns:

this object.  

setTimeouts

jsx3.net.Request setTimeouts(intResolveTimeout : int, intConnectTimeout : int, intSendTimeout : int, intReceiveTimeout : int)
Deprecated. IE only.
Specifies timeout settings for resolving the domain name, establishing the connection to the server, sending the data, and receiving the response. The timeout parameters of the setTimeouts method are specified in milliseconds, so a value of 1000 would represent 1 second. A value of zero represents an infinite timeout. There are four separate timeout parameters: resolveTimeout, connectTimeout, sendTimeout, and receiveTimeout. When calling the setTimeouts method, all four values must be specified. The timeouts are applied at the Winsock layer.

Parameters:

intResolveTimeoutThe value is applied to mapping host names (such as "www.microsoft.com") to IP addresses; the default value is infinite, meaning no timeout.
intConnectTimeoutThe value is applied to establishing a communication socket with the target server, with a default timeout value of 60 seconds.
intSendTimeoutThe value applies to sending an individual packet of request data (if any) on the communication socket to the target server. A large request sent to a server will normally be broken up into multiple packets; the send timeout applies to sending each packet individually. The default value is 5 minutes.
intReceiveTimeoutThe value applies to receiving a packet of response data from the target server. Large responses will be broken up into multiple packets; the receive timeout applies to fetching each packet of data off the socket. The default value is 60 minutes.

Returns:

this instance. 

jsx3.net

class Service

Object
->jsx3.lang.Object
  ->jsx3.net.Service

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Service
extends jsx3.lang.Object
This class is used in conjunction with the XML Mapping Utility to provide transactional support for those services using XML-based messaging. Support includes those services defined via Schema, XML, XHTML, and WSDL (SOAP). In practice a developer would open General Interface Builder to access the XML Mapping Utility. They would then point the utility at a "pattern master" (i.e., WSDL, Schema, XML, etc) and begin using its visual tools to bind application objects to nodes in the XML messages to be sent and received. The output from the Mapping Utility is referred to as a mapping rule set. This rule set is an XML document based upon the Common Exchange Format (CXF) and defines the information necessary to support transactional data mapping. Many of the APIs available to the Service class allow the devloper to dynamically update various static values that were set using the XML Mapping Utility.

Field Summary
static String
event type for unsuccessful response
static String
Event type published each time a rule with one or more restrictions fails during message generation.
static String
Event type published each time a mapping rule is used to create a node, locate a node, or map to a node.
static String
event type for successful response
static String
Event type published when the response is still not ready after the specified timeout period.
static String
XML namespace for JSON objects when converted to XML
Constructor Summary
void
init(strRulesURL : String, strOperationName : String, strOutboundURL : String, strInboundURL : String)
instance initializer
Method Summary
static jsx3.xml.Document
JSON2XML(objJ : String | Object)
Converts a JSON object to an XML document belonging to the namespace URI, http://xsd.tns.tibco.com/gi/json/2007/.
static String | null
Converts an XML document belonging to the namespace URI, http://xsd.tns.tibco.com/gi/json/2007/, into a serialized JSON String.
void
Deprecated. Renamed to setRequestHeader.
jsx3.xml.Document
Compiles the CXF rules for this service instance to an equivalent XSLT document.
boolean
doCall(bCancelIfInvalid : boolean)
Generates the request message (if applicable) and sends to the remote service.
void
Applies all inbound mappings, using the server response document as the source for the operation.
void
doRespond(objEvent : Object)
Provides a method to manually trigger the response chain by initiating the response event for the instance.
String
Gets the URL for the service endpoint where the request will be sent
jsx3.xml.Document
Call this method after the service has responded to get a parsed instance of the server's XML response
String
Gets the URL for a "typical", XML-formatted server resonse document.
boolean
If true, the Script transport will use JSONP
String
Gets the method for the request.
jsx3.Boolean
Gets the mode (static jsx3.Boolean.FALSE or live jsx3.Boolean.TRUE).
String
Gets the namespace for the server/project to run the service instance within.
void
Deprecated. Renamed to getOperationName.
String
Gets the name of the operation to use within a multi-operation rules file.
jsx3.xml.Document
Call this method after 'doCall' has been called to get a parsed instance of the request document--what was actually sent to the remote service
String
Gets XPath address for the node in the outbound stub document to which to append the generated message.
String | null
Gets URL for the base stub to use for the request message (the XML document to contain the generated document)
String
Gets URL for a 'typical' XML-formatted request document to send to the server; when this is set, the mapper does not even attempt to generate a document.
jsx3.net.Request
Gets the jsx3.net.HttpRequest instance that performs the transaction with the remote service (the transport object for the message).
String
Gets the URL for the rules file to use (a CXF document).
jsx3.xml.Document
Returns the rules document used by the Service instance (a CXF document)
jsx3.app.Server
Returns the server that this service runs in, as set by the setNamespace() method.
jsx3.xml.Document
getServiceMessage(MESSAGETYPE : String, strShellURL : String)
Gets the request message specific to the MESSAGETYPE (input, output, fault).
int
Gets the HTTP response code (i.e.
void
Deprecated. Renamed to getOutboundStubURL.
String
Returns a CR-LF delimited list of supported namespaces and thei related prefix (as defined by the Object, jsx3.net.Service.
String
Gets user name to send as part of the http request (for servers requiring http authentication)
String
Gets password to send as part of the http request (for servers requiring http authentication)
static void
Deprecated.
jsx3.xml.Document
Deprecated. The WSDL is no longer relevant to the Service class as the rules file will contain all information necessary to generate and process the Service interaction.
jsx3.net.Service
Resets the rules tree to default state (with all 'skip' flags removed) from those rules that were skipped during the previous transaction
jsx3.net.Service
Dereferences the parsed rules tree (a jsx3.xml.Document instance) managed by this Service instance, forcing a reload of the document from disk the next time the rules document is requested
jsx3.net.Service
setEndpointURL(strAlternateURL : String)
Sets the URL for the service endpoint where the request will be sent.
void
Sets a parsed instance of the response document as soon as it returns from the server returned from the service; otherwise null
jsx3.net.Service
setInboundURL(strInboundURL : String)
Sets the URL for a "typical", XML-formatted server resonse document.
void
setJSONP(bJSONP : boolean | String)
If set to true, the service class will append an additional parameter to the URL in the form, callback={method}, where {method} is a temporary callback function managed by the Service instance.
void
setMethod(METHOD : String)
Sets the method for the request different than the one described in the rules file.
void
Sets the mode (static jsx3.Boolean.FALSE or live jsx3.Boolean.TRUE).
jsx3.net.Service
Sets the namespace for the server/project to run the service instance within.
jsx3.net.Service
setOnError(vntItem : String | Object | Function)
Deprecated. Use jsx3.EventDispatcher interface instead with event type jsx3.net.Service.ON_ERROR.
jsx3.net.Service
Deprecated. Use jsx3.EventDispatcher interface instead with event type jsx3.net.Service.ON_SUCCESS.
void
Deprecated. Renamed to setOperationName.
jsx3.net.Service
setOperationName(strOperationName : String)
Sets the name of the operation to use within a multi-operation rules file.
jsx3.net.Service
Sets the document that will serve as the container for the message generated by doCall and/or getServiceMessage.
jsx3.net.Service
Sets XPath address for the node in the outbound stub document to which to append the generated message.
jsx3.net.Service
Sets the URL to the document that will serve as the container for the message generated by doCall and/or getServiceMessage.
jsx3.net.Service
setOutboundURL(strOutboundURL : String)
Sets the URL for a static XML-formatted request document to send to the Service.
void
setRequestHeader(strName : String, strValue : String)
Sets an HTTP Request header on the request.
jsx3.net.Service
setRulesURL(strRulesURL : String)
Sets the URL for the rules file to use (a CXF document).
void
Deprecated. Renamed to setEndpointURL.
void
setStatus(intStatus : int)
Sets the HTTP response code (i.e.
void
Deprecated. Renamed to setOutboundStubURL.
jsx3.net.Service
setTimeout(intTimeout : int, objHandler : Object | String | function, objFunction : function | String)
Specifies how long to wait for the service to respond before cancelling the call.
jsx3.net.Service
setTimeouts(intResolveTimeout : int, intConnectTimeout : int, intSendTimeout : int, intReceiveTimeout : int)
Deprecated. Due to browser security constraints, this method is no longer used. Use setTimeout instead. This method no longer affects any aspect of the Service call.
jsx3.net.Service
setUserName(strName : String)
Sets the user name to send with the posting (for those sites requiring http authentication)
jsx3.net.Service
setUserPass(strPass : String)
Sets the password to send with the posting (for those sites requiring http authentication)
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

ON_ERROR

static final String ON_ERROR
event type for unsuccessful response

ON_INVALID

static final String ON_INVALID
Event type published each time a rule with one or more restrictions fails during message generation. The following named properties are available on the event object:
  • rule the rule node
  • message the message node
  • target this jsx3.net.Service instance
  • type the type of restriction that caused the invalidation event to be publsihed. For example, pattern.
  • value the value for the type. For example if type is pattern, then [A-Z]*

ON_PROCESS_RULE

static final String ON_PROCESS_RULE
Event type published each time a mapping rule is used to create a node, locate a node, or map to a node.
  • target this jsx3.net.Service instance
  • rule the rule node being processed
  • action the action being performed by the rule. For example, Create Node, Map to Cache, Invalidate Node, etc.
  • description a description of the 'action'. For example, this.eval(setValue(2));
  • level the log level (e.g., 'severity' level) for the message. For example, 6 would signify a 'Trace' level event.

ON_SUCCESS

static final String ON_SUCCESS
event type for successful response

ON_TIMEOUT

static final String ON_TIMEOUT
Event type published when the response is still not ready after the specified timeout period.

json_namespace

static final String json_namespace
XML namespace for JSON objects when converted to XML
Constructor Detail

init

void init(strRulesURL : String, strOperationName : String, strOutboundURL : String, strInboundURL : String)
instance initializer

Parameters:

strRulesURLThe resolved URI for the rules document (a CXF document). Note: since this class is lazily loaded as of v3.2, the preferred method of instantiating this class is by calling the loadResource method on the context server (jsx3.app.Server) instance. This ensures proper URL resolution while also establishing the appropriate server context.
strOperationNamename of operation to call. This is only required if the rules file was generated via a WSDL.
strOutboundURLaddress of a sample outbound message to use as opposed to the one generated by the tool
strInboundURLwhen the project is run in static mode (as defined by the 'project deployment options' dialog), this document is used to simulate a typical server response
Method Detail

JSON2XML

static jsx3.xml.Document JSON2XML(objJ : String | Object)
Converts a JSON object to an XML document belonging to the namespace URI, http://xsd.tns.tibco.com/gi/json/2007/. This document can then be converted back to the same JSON format by calling the complimentary method, XML2JSON.

Parameters:

objJSerialized JSON

Throws:

{jsx3.lang.Exception}if objJ can not be evaluated as a valid JavaScript Object

Returns:

 

See Also:

,

XML2JSON

static String | null XML2JSON(objXML : jsx3.xml.Document)
Converts an XML document belonging to the namespace URI, http://xsd.tns.tibco.com/gi/json/2007/, into a serialized JSON String. This String, when evaluated, can then be converted back to the original document format by calling the complimentary method, JSON2XML.

Parameters:

objXML

Returns:

serialized JSON Object or null if document did not belong to the correct namepace 

See Also:

,

addHeader

void addHeader()
Deprecated. Renamed to setRequestHeader.

compile

jsx3.xml.Document compile()
Compiles the CXF rules for this service instance to an equivalent XSLT document. This enables much faster performance than using the DOM-based iterator (default) to convert the XML response document into a CDF Document type. Note that this process only supports the map types CDF Document, CDF Record, and CDF Attribute. Only one CDF Document can be declared per Operation. Otherwise the compilation will fail. All other mapping types will be ignored and will not be converted into an XSLT equivalent. Also note that the order of a set of sibling mapping rules does not proscribe proper processing by way of sequence. This means that any order of sibling mapping rules will result in appropriate processing, regardless of the sibling node order returned from the given service. This facilitates nested record structures in that attributes can first be applied to a given record before child elements (e.g., a 'record') are added. Stated otherwise, any rule that has a descendant rule that would created a nested 'record' node should follow all sibling mapping rules that would create an 'attribute' entity. Call this method immediately before/after doCall for best performance.

Returns:

XSLT document  

doCall

boolean doCall(bCancelIfInvalid : boolean)
Generates the request message (if applicable) and sends to the remote service.

Parameters:

bCancelIfInvalidIf true, the remote service will not be called if the message does not pass validation while being generated.

Returns:

true if the message passed all validation rules while being generated.  

doInboundMap

void doInboundMap()
Applies all inbound mappings, using the server response document as the source for the operation. Although this method is called once automatically, it can be called at any time to reapply the mapping rules. Example usage: var oService = new jsx3.net.Service(); oService.setInboundDocument(objSomeDocumentIManuallyWantToLoad); oService.doInboundMap();

doRespond

void doRespond(objEvent : Object)
Provides a method to manually trigger the response chain by initiating the response event for the instance. One parameter can be passed to simulate the server response: objEvent. Based upon the properties contained by this object, the response will be handled differently by the response handler. The named properties are as follows:
  • target: A jsx3.net.Request instance or a JavaScript object that provides the methods, getResponseXML (to handle XML-formatted responses) or getResponseText (to handle JSON-formatted responses). If the event object does not expose the 'target' property and/or if the 'target' does not expose the methods getResponseText or getResponseXML, it is assumed that objEvent is a JSON object--the response itself.

Parameters:

objEventEvent object with named property, target; or JSON object

getEndpointURL

String getEndpointURL()
Gets the URL for the service endpoint where the request will be sent

Returns:

 

getInboundDocument

jsx3.xml.Document getInboundDocument()
Call this method after the service has responded to get a parsed instance of the server's XML response

Returns:

 

getInboundURL

String getInboundURL()
Gets the URL for a "typical", XML-formatted server resonse document. This document is then used when the project is run in static mode (as defined by the Project Deployment Options).

Returns:

 

getJSONP

boolean getJSONP()
If true, the Script transport will use JSONP

Returns:

 

getMethod

String getMethod()
Gets the method for the request. Default is POST

Returns:

GET, POST, PUT, DELETE, or SCRIPT  

getMode

jsx3.Boolean getMode()
Gets the mode (static jsx3.Boolean.FALSE or live jsx3.Boolean.TRUE).

Returns:

 

getNamespace

String getNamespace()
Gets the namespace for the server/project to run the service instance within. If a namespace isn't provided, the system will look for the first application and use its namespace. If no applications exist, the namespace will be completely ignored.

Returns:

 

getOperation

void getOperation()
Deprecated. Renamed to getOperationName.

getOperationName

String getOperationName()
Gets the name of the operation to use within a multi-operation rules file. Note: Rules created via a WSDL often have multiple named operations. Rules files generated without a WSDL contain no named operations, and instead use a single transaction.

Returns:

 

getOutboundDocument

jsx3.xml.Document getOutboundDocument()
Call this method after 'doCall' has been called to get a parsed instance of the request document--what was actually sent to the remote service

Returns:

 

getOutboundStubPath

String getOutboundStubPath()
Gets XPath address for the node in the outbound stub document to which to append the generated message.

Returns:

Valid XSL path  

getOutboundStubURL

String | null getOutboundStubURL()
Gets URL for the base stub to use for the request message (the XML document to contain the generated document)

Returns:

 

getOutboundURL

String getOutboundURL()
Gets URL for a 'typical' XML-formatted request document to send to the server; when this is set, the mapper does not even attempt to generate a document. Instead, this document is sent directly to the server without any processing. Useful for testing requests that never change

Returns:

 

getRequest

jsx3.net.Request getRequest()
Gets the jsx3.net.HttpRequest instance that performs the transaction with the remote service (the transport object for the message).

Returns:

 

getRulesURL

String getRulesURL()
Gets the URL for the rules file to use (a CXF document). This rules file will be used by the Service instance to generate, send, receive and process XML messages

Returns:

 

getRulesXML

jsx3.xml.Document getRulesXML()
Returns the rules document used by the Service instance (a CXF document)

Returns:

 

getServer

jsx3.app.Server getServer()
Returns the server that this service runs in, as set by the setNamespace() method.

Returns:

 

See Also:


getServiceMessage

jsx3.xml.Document getServiceMessage(MESSAGETYPE : String, strShellURL : String)
Gets the request message specific to the MESSAGETYPE (input, output, fault). Typically only used for input (outbound) messages, but can be used for simulating a server response for output and fault (in the case of a SOAP transaction, fault) messages

Parameters:

MESSAGETYPEone of: input, output, or fault. If this value is provided, the server will generate test data for all nodes lacking a mapped or scripted value
strShellURLrelative URL to message shell to use as the starting container to put content into. Note that calling setOutboundStubURL or setOutboundStubDocument in conjunction with setOutboundStubPath are preferred to passing this parameter, since they provide much greater control. Also note that this value is stored statically in the rules document when the rules document is first created via the XML Mapping Utility.

Returns:

 

getStatus

int getStatus()
Gets the HTTP response code (i.e., 200, 404, 500, etc). This will be the response code provided by the bound jsx3.net.Request instance used for the transport. However, if setStatus has been called on the Service instance, the value supplied by the developer will be used instead.

Returns:

 

getStubURL

void getStubURL()
Deprecated. Renamed to getOutboundStubURL.

getSupportedNamespaces

String getSupportedNamespaces()
Returns a CR-LF delimited list of supported namespaces and thei related prefix (as defined by the Object, jsx3.net.Service._ns). Any nodes in a rules document (CXF) that implements one of the namespaces listed by this function, should implement the corresponding namespace prefix as also detailed here.

Returns:

 

getUserName

String getUserName()
Gets user name to send as part of the http request (for servers requiring http authentication)

Returns:

 

getUserPass

String getUserPass()
Gets password to send as part of the http request (for servers requiring http authentication)

Returns:

 

getVersion

static void getVersion()
Deprecated.
Gets the release/build for the class (i.e., "2.2.00") @ returns {String}

getWSDL

jsx3.xml.Document getWSDL()
Deprecated. The WSDL is no longer relevant to the Service class as the rules file will contain all information necessary to generate and process the Service interaction.
Gets the parsed WSDL (what was used as the original input to create the rules file being used by this service instance).

Returns:

 

resetRules

jsx3.net.Service resetRules()
Resets the rules tree to default state (with all 'skip' flags removed) from those rules that were skipped during the previous transaction

Returns:

reference to self  

resetRulesTree

jsx3.net.Service resetRulesTree()
Dereferences the parsed rules tree (a jsx3.xml.Document instance) managed by this Service instance, forcing a reload of the document from disk the next time the rules document is requested

Returns:

reference to self  

setEndpointURL

jsx3.net.Service setEndpointURL(strAlternateURL : String)
Sets the URL for the service endpoint where the request will be sent. Overrides the endpoint specified in the rules file.

Parameters:

strAlternateURL

Returns:

reference to self  

setInboundDocument

void setInboundDocument(objXML : jsx3.xml.Document)
Sets a parsed instance of the response document as soon as it returns from the server returned from the service; otherwise null

Parameters:

objXML

setInboundURL

jsx3.net.Service setInboundURL(strInboundURL : String)
Sets the URL for a "typical", XML-formatted server resonse document. This document is then used when the project is run in static mode (as defined by the Project Settings dialog). Overrides the static setting in the rules file.

Parameters:

strInboundURLAlternate URL for the "typical" Service response. Note that this URL will be resolved relative to the context server. For example, if the project directory for the context server is 'test', then the following inputs (all of which are valid) are equivalent: jsxapp://test/xml/typical.xml, and xml/typical.xml, and JSXAPPS/test/xml/typical.xml

Returns:

reference to self 

See Also:


setJSONP

void setJSONP(bJSONP : boolean | String)
If set to true, the service class will append an additional parameter to the URL in the form, callback={method}, where {method} is a temporary callback function managed by the Service instance. This allows for flexibility when using JSON Services that are also available as JSONP Services, in that the same URL can be used (setEndpointURL) but different behaviors can be implemented. If the given JSONP Service uses a callback name different than "callback", pass the parameter name expected by the given JSON Service. You may also implement a callback of your own by directly modifying the endpoint URL to call the named function of your choosing. In such situations, pass false to this method, so the transport will not attempt any form of callback. If you do choose to implement your own callback handlers, you must manually conclude the service call with a call to doRespond.

Parameters:

bJSONP

See Also:

,

setMethod

void setMethod(METHOD : String)
Sets the method for the request different than the one described in the rules file.

Parameters:

METHODGET, POST, PUT, DELETE, or SCRIPT

setMode

void setMode(MODE : jsx3.Boolean)
Sets the mode (static jsx3.Boolean.FALSE or live jsx3.Boolean.TRUE). Overrides the default setting for the context Server instance within which this Service instnace is running. (NOTE: This setting is accessible at the server level via the Project Settings dialog.) Setting this value to jsx3.Boolean.FALSE, forces a test document to be used to simulate a "typical" server response, instead of actually sending a request to a remote service. This is useful when setting up test environments as well as providing "live" interactions when the remote server may not be available.

Parameters:

MODE

See Also:


setNamespace

jsx3.net.Service setNamespace(namespace : jsx3.app.Server | String)
Sets the namespace for the server/project to run the service instance within.

Parameters:

namespacethe server (preferred) or the namespace of the server.

Returns:

this object  

setOnError

jsx3.net.Service setOnError(vntItem : String | Object | Function)
Deprecated. Use jsx3.EventDispatcher interface instead with event type jsx3.net.Service.ON_ERROR.
sets the script that will fire after the service has failed; if a soap fault envelope is returned, this will be processed as would any mapped tree. Allows for object repaints, cleanup, etc.

Parameters:

vntItemeither a script (as string) to execute via eval or a function that will be notified. Note: this function will receive a single parameter, a reference to this jsx3.net.Service instance

Returns:

reference to self 

setOnSuccess

jsx3.net.Service setOnSuccess(vntItem : String | Object | Function)
Deprecated. Use jsx3.EventDispatcher interface instead with event type jsx3.net.Service.ON_SUCCESS.
Sets the script that will fire after the service has finished an inbound mapping or a function to callback to; allows for object repaints, cleanup, etc

Parameters:

vntItemeither a script (as string) to execute via eval or a function that will be notified when the service call completes. Note: this function will receive a single parameter, a reference to this jsx3.net.Service instance

Returns:

reference to self 

setOperation

void setOperation()
Deprecated. Renamed to setOperationName.

setOperationName

jsx3.net.Service setOperationName(strOperationName : String)
Sets the name of the operation to use within a multi-operation rules file. Note: Rules created via a WSDL often have multiple operations

Parameters:

strOperationNameoperation name

Returns:

reference to self  

setOutboundStubDocument

jsx3.net.Service setOutboundStubDocument(objDocument : jsx3.xml.Document)
Sets the document that will serve as the container for the message generated by doCall and/or getServiceMessage. This is a useful way to dynamically assemble documents by chaining multiple service instances, using the output from one service as the input to another. For example, when a SOAP Envelope requires both a SOAP Header as well as a SOAP Body, this method allows the Envelope to be assembled via a two-step process of first adding mapped content to the Body, followed by a call to add mapped content to the Header. Note that this method takes precedence over the static stub document url referenced in the rules file as well as any call to setOutboundStubURL. Use this method in conjunction with setOutboundStubPath to point to the specific location in the document where the generated message should be appended.

Parameters:

objDocument

Returns:

reference to self 

See Also:

,

setOutboundStubPath

jsx3.net.Service setOutboundStubPath(strPath : String)
Sets XPath address for the node in the outbound stub document to which to append the generated message. Overrides the static setting in the rules file.

Parameters:

strPathValid XSL path. For example, /SOAP-ENV:Envelope/SOAP-ENV:Body

Returns:

reference to self 

See Also:

,

setOutboundStubURL

jsx3.net.Service setOutboundStubURL(strURL : String)
Sets the URL to the document that will serve as the container for the message generated by doCall and/or getServiceMessage. Overrides the static setting stored in the rules file. Use this method in conjunction with setOutboundStubPath to point to the specific location in the document where the generated message should be appended.

Parameters:

strURLURL for the document. Note that this URL will be resolved relative to the context server. For example, if the project directory for the context server is 'test', then the following inputs (all of which are valid) are equivalent: jsxapp://test/xml/typical.xml, and xml/typical.xml, and JSXAPPS/test/xml/typical.xml

Returns:

reference to self 

See Also:


setOutboundURL

jsx3.net.Service setOutboundURL(strOutboundURL : String)
Sets the URL for a static XML-formatted request document to send to the Service. Note that when this is set, the mapper does not even attempt to generate a request document via the rules file. Instead, the static request document is sent directly to the remote Service without any processing. This is useful for requests that never change or as a means to test whether a Service is working, using a known, valid input.

Parameters:

strOutboundURLAlternate URL for the static request to send. Note that this URL will be resolved relative to the context server. For example, if the project directory for the context server is 'test', then the following inputs (all of which are valid) are equivalent: jsxapp://test/xml/typical.xml, and xml/typical.xml, and JSXAPPS/test/xml/typical.xml

Returns:

reference to self  

setRequestHeader

void setRequestHeader(strName : String, strValue : String)
Sets an HTTP Request header on the request. Set before calling, doCall()

Parameters:

strNamename for header parameter
strValuevalue for the header parameter

setRulesURL

jsx3.net.Service setRulesURL(strRulesURL : String)
Sets the URL for the rules file to use (a CXF document). This rules file will be used by the Service instance to generate, send, receive and process XML messages

Parameters:

strRulesURL

Returns:

reference to self  

setServiceURL

void setServiceURL()
Deprecated. Renamed to setEndpointURL.

setStatus

void setStatus(intStatus : int)
Sets the HTTP response code (i.e., 200, 404, 500, etc). Typically, the Service instance determines this value by querying the bound request instance (jsx3.net.Request) returned by the method, [service_instance].getRequest(). However, calling this method will override normal operation by forcing a valid/invalid state that affects methdods relying on the HTTP status such as doInboundMap. This is particularly useful for SOAP services that provide alternate processing instructions and mappings when a Fault occurs as well as when running tests in Static mode.

Parameters:

intStatus

setStubURL

void setStubURL()
Deprecated. Renamed to setOutboundStubURL.

setTimeout

jsx3.net.Service setTimeout(intTimeout : int, objHandler : Object | String | function, objFunction : function | String)
Specifies how long to wait for the service to respond before cancelling the call. Subscribes to the ON_TIMEOUT event

Parameters:

intTimeoutnumber of milliseconds to wait befor publishing the ON_TIMEOUT event.
objHandlerif an object, the instance to notify of events (objFunction is required); if a string, the JSX id of the instance to notify of events (objFunction is required), must exist in the same Server; if a function, the function to call to notify of events (objFunction ignored)
objFunctionif objHandler is a string or object then the function to call on that instance. either a function or a string that is the name of a method of the instance

Returns:

reference to self  

setTimeouts

jsx3.net.Service setTimeouts(intResolveTimeout : int, intConnectTimeout : int, intSendTimeout : int, intReceiveTimeout : int)
Deprecated. Due to browser security constraints, this method is no longer used. Use setTimeout instead. This method no longer affects any aspect of the Service call.
Specifies timeout settings for resolving the domain name, establishing the connection to the server, sending the data, and receiving the response. The timeout parameters of the setTimeouts method are specified in milliseconds, so a value of 1000 would represent 1 second. A value of zero represents an infinite timeout. There are four separate timeout parameters: resolveTimeout, connectTimeout, sendTimeout, and receiveTimeout. When calling the setTimeouts method, all four values must be specified. The timeouts are applied at the Winsock layer.

Parameters:

intResolveTimeoutThe value is applied to mapping host names (such as "www.microsoft.com") to IP addresses; the default value is infinite, meaning no timeout.
intConnectTimeoutThe value is applied to establishing a communication socket with the target server, with a default timeout value of 60 seconds.
intSendTimeoutThe value applies to sending an individual packet of request data (if any) on the communication socket to the target server. A large request sent to a server will normally be broken up into multiple packets; the send timeout applies to sending each packet individually. The default value is 5 minutes.
intReceiveTimeoutThe value applies to receiving a packet of response data from the target server. Large responses will be broken up into multiple packets; the receive timeout applies to fetching each packet of data off the socket. The default value is 60 minutes.

Returns:

reference to self 

setUserName

jsx3.net.Service setUserName(strName : String)
Sets the user name to send with the posting (for those sites requiring http authentication)

Parameters:

strNameuser name

Returns:

reference to self  

setUserPass

jsx3.net.Service setUserPass(strPass : String)
Sets the password to send with the posting (for those sites requiring http authentication)

Parameters:

strPasspassword for user

Returns:

reference to self  

jsx3.net

class URI

Object
->jsx3.lang.Object
  ->jsx3.net.URI

class URI
extends jsx3.lang.Object
Represents a Uniform Resource Identifier (URI) reference. Modeled on the Java class java.net.URI.

Since:

3.1

Constructor Summary
void
init(strURI : String)
Instance initializer.
Method Summary
boolean
equals(obj : ?)
static jsx3.net.URI
fromParts(scheme : String, userInfo : String, host : String, port : int, path : String, query : String, fragment : String)
This method can be called with either 3 or 7 arguments.
String
String
String
String
int
String
String | boolean
getQueryParam(strParam : String)
Searches the query part for the value of a parameter.
Object<String, String>
String
String
String
boolean
boolean
jsx3.net.URI
Normalizes this URI's path.
jsx3.net.URI
Relativizes the given URI against this URI.
jsx3.net.URI
Resolves the given URI against this URI.
String
static jsx3.net.URI
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strURI : String)
Instance initializer.

Parameters:

strURIuri
Method Detail

equals

boolean equals(obj : ?)

Parameters:

obj

Returns:

 

Overrides:


fromParts

static jsx3.net.URI fromParts(scheme : String, userInfo : String, host : String, port : int, path : String, query : String, fragment : String)
This method can be called with either 3 or 7 arguments. If it is called with 3 arguments, the signature is URI.fromParts(scheme, schemeSpecificPath, fragment).

Parameters:

schemethe URI scheme, may be null
userInfothe URI user-information, may be null; or the scheme-specific part if called with 3 arguments
hostthe URI host, may be null; or the URI fragment if called with 3 arguments, may be null
portthe URI port, may be null
paththe URI path
querythe URI query, may be null
fragmentthe URI fragment, may be null

Returns:

 

getAuthority

String getAuthority()

Returns:

 

getFragment

String getFragment()

Returns:

 

getHost

String getHost()

Returns:

 

getPath

String getPath()

Returns:

 

getPort

int getPort()

Returns:

 

getQuery

String getQuery()

Returns:

 

getQueryParam

String | boolean getQueryParam(strParam : String)
Searches the query part for the value of a parameter. Parameters are specified as name value pairs delimited by '&' like: name1=value1&name2=value2&... If a parameter is specified without a following '=' this method will return boolean true.

Parameters:

strParam

Returns:

 

getQueryParams

Object<String, String> getQueryParams()

Returns:

 

getScheme

String getScheme()

Returns:

 

getSchemeSpecificPart

String getSchemeSpecificPart()

Returns:

 

getUserInfo

String getUserInfo()

Returns:

 

isAbsolute

boolean isAbsolute()

Returns:

 

isOpaque

boolean isOpaque()

Returns:

 

normalize

jsx3.net.URI normalize()
Normalizes this URI's path.

Returns:

 

relativize

jsx3.net.URI relativize(uri : String | jsx3.net.URI)
Relativizes the given URI against this URI.

The returned URI is computed as follows:
  1. If this URI or uri is opaque, or their schemes are not equal or their authorities are not equal, uri is returned.
  2. Otherwise, a new URI is constructed with the query and fragment of uri and a path equal to:
    1. If the common path prefix of this URI and uri is just "" or "/", the path of uri
    2. Otherwise, the last segment of this path is removed and the path is computed by removing any common path prefix between the two paths, prepending a ".." for every segment remaining in this path, and appending the remaining path of uri.

Parameters:

uri

Returns:

 

resolve

jsx3.net.URI resolve(uri : String | jsx3.net.URI)
Resolves the given URI against this URI.

Parameters:

uri

Returns:

 

toString

String toString()

Returns:

 

Overrides:


valueOf

static jsx3.net.URI valueOf(strURI : String | jsx3.net.URI)

Parameters:

strURI

Returns:

 

jsx3.net

interface URIResolver

jsx3.net.URIResolver

All Known Implementing Classes:

jsx3.amp.PlugIn, jsx3.app.AddIn, jsx3.app.Server

abstract interface URIResolver
An interface specifying the methods necessary to define a context against which URIs are resolved.

Since:

3.2

Field Summary
static jsx3.net.URIResolver
The default URI resolver.
static jsx3.net.URIResolver
Resolves URIs according to the default resolver except that all relative URIs are resolved relative to the JSX/ directory.
static jsx3.net.URIResolver
Resolves URIs according to the default resolver except that all relative URIs are resolved relative to the user directory (or JSXAPPS/.
Method Summary
static jsx3.net.URIResolver
Returns the resolver explicitly referenced in the scheme, host, and path parts of the URI strURI.
abstract String
Returns the URI prefix that when prepended to relative URIs resolves them.
static boolean
Returns whether the URI strURI is considered absolute in the JSX system.
static void
register(strScheme : String, objResolver : jsx3.net.URIResolver | Function)
abstract jsx3.net.URI
relativizeURI(strURI : String | jsx3.net.URI, bRel : boolean)
Transforms a URI relative to the URL of the HTML page containing the JSX system into an absolute URI defined in relation to this resolver.
abstract jsx3.net.URI
Resolves the URI strURI against the base context of this resolver.
Field Detail

DEFAULT

static jsx3.net.URIResolver DEFAULT
The default URI resolver. This resolver can resolve any of the absolute URI formats supported by the system. Other absolute URIs and all relative URIs are unmodified. The absolute URI formats are:
  • JSX/...
  • JSXAPPS/...
  • GI_Builder/...
  • jsx:/...
  • jsxapp://appPath/...
  • jsxaddin://addinKey/...
  • jsxuser:/...

JSX

static jsx3.net.URIResolver JSX
Resolves URIs according to the default resolver except that all relative URIs are resolved relative to the JSX/ directory. This resolver resolves the following URIs to the same value:
  • JSX/file.xml
  • jsx:/file.xml
  • file.xml

USER

static jsx3.net.URIResolver USER
Resolves URIs according to the default resolver except that all relative URIs are resolved relative to the user directory (or JSXAPPS/../). This resolver resolves the following URIs to the same value:
  • JSXAPPS/../file.xml
  • jsxuser:/file.xml
  • file.xml
Method Detail

getResolver

static jsx3.net.URIResolver getResolver(strURI : String | jsx3.net.URI)
Returns the resolver explicitly referenced in the scheme, host, and path parts of the URI strURI. This method returns the the following values depending URI:
  • jsx: – URIResolver.JSX.
  • jsxapp: – and instance of URIResolver capable of resolving URIs relative to the base directory of the application corresponding to the host part of the URI.
  • jsxaddin: – the instance of jsx3.app.AddIn corresponding to the host part of the URI. If the addin is not loaded then null is returned.
  • jsxuser: – URIResolver.USER.
  • JSX/ – URIResolver.DEFAULT.
  • JSXAPPS/ – URIResolver.USER.
  • GI_Builder/ – URIResolver.DEFAULT.
  • otherwise null.

Parameters:

strURI

Returns:

 

getUriPrefix

abstract String getUriPrefix()
Returns the URI prefix that when prepended to relative URIs resolves them. This prefix may include "../" path segments.

Returns:

 

isAbsoluteURI

static boolean isAbsoluteURI(strURI : String | jsx3.net.URI)
Returns whether the URI strURI is considered absolute in the JSX system. Implementors of the URIResolver interface should always delegate resolution of absolute URIs to the default resolver. This method is not equivalent to URI.isAbsolute() because, for example, URIs beginning with "JSX/" are considered absolute in the JSX system.

Parameters:

strURI

Returns:

 

register

static void register(strScheme : String, objResolver : jsx3.net.URIResolver | Function)

Parameters:

strScheme
objResolver

relativizeURI

abstract jsx3.net.URI relativizeURI(strURI : String | jsx3.net.URI, bRel : boolean)
Transforms a URI relative to the URL of the HTML page containing the JSX system into an absolute URI defined in relation to this resolver. When resolved against any resolver, the returned URI resolves to strURI.

Parameters:

strURI
bRel

Returns:

 

resolveURI

abstract jsx3.net.URI resolveURI(strURI : String | jsx3.net.URI)
Resolves the URI strURI against the base context of this resolver. Converts a URI relative to this resolver into a URI relative to the URL of the HTML page containing the JSX system. Implementations of this method should delegate to the default resolver any URIs that are judged to be absolute by the method URIResolver.isAbsoluteURI().

Parameters:

strURI

Returns:

 

See Also:


package jsx3.util

Utility classes.

Class Summary
jsx3.util.Collection
Deprecated. Subsumed by jsx3.util.List.
jsx3.util.DateFormat
Formats and parses dates according to a token-based string format.
jsx3.util.Dojo
Provides the ability to load the Dojo JavaScript library.
jsx3.util.EventDispatcher
An Event Dispatcher mixin interface, adds the ability to register event listeners and dispatch events to those listeners.
jsx3.util.GNode
jsx3.util.Graph
jsx3.util.Iterator
An interface that defines an object that can be iterated over.
jsx3.util.Job
jsx3.util.JobGraph
jsx3.util.List
An object-oriented version of the built-in JavaScript Array class.
jsx3.util.Locale
Represents a region of the world.
jsx3.util.Logger
A Logger is used to log messages about a particular component of an application.
jsx3.util.Logger.AlertHandler
Handles a logging record by sending it to a JavaScript alert.
jsx3.util.Logger.ConsoleHandler
Handles a logging record by sending it to the Firebug console.
jsx3.util.Logger.FormatHandler
A subclass of Handler that includes functionality for formatting logging records as human-readable strings.
jsx3.util.Logger.Handler
The base logging handler class.
jsx3.util.Logger.Manager
Manager class for the logging system.
jsx3.util.Logger.MemoryHandler
A simple Handler class that stores a rotating cache of log records in memory.
jsx3.util.Logger.Record
Record bean that stores information about a logging message.
jsx3.util.MessageFormat
Constructs messages from a pattern and parameters.
jsx3.util.NumberFormat
Formats numbers.
Method Summary
static int
arrIndexOf(a : Array, o : Object)
Returns the array index of o in a.
static boolean
Returns v == null || isNaN(v).
static Number
numMod(v : Number, mod : Number)
Calculates a mod b, but the result is not allowed to be negative.
static Number
numRound(v : Number, intUnit : int)
Rounds v to the nearest value that can be divided by intUnit.
static String
Returns the result of decoding s from its base-64 equivalent.
static boolean
Returns whether s is null or an empty string.
static String
Returns the result of encoding s to its base-64 equivalent.
static boolean
strEndsWith(s : String, strTest : String)
Returns whether s ends with strTest.
static String
Returns s with the following four characters replaced by their escaped equivalent: & < > ".
static String
Returns str appropriately formatted and escaped for use as a JSON string.
static String
Returns s trimmed of trailing and leading spaces (anything matching the regexp /\s/).
static String
strTruncate(s : String, intMax : int, strEllipsis : String, fltPos : Number)
Limits s to length intMax by placing an ellipsis in values that are too long.
Method Detail

arrIndexOf

static int arrIndexOf(a : Array, o : Object)
Returns the array index of o in a. Comparisons are performed with strict equals (===).

Parameters:

a
o

Returns:

 

numIsNaN

static boolean numIsNaN(v : Object)
Returns v == null || isNaN(v).

Parameters:

vany value.

Returns:

 

Since:

3.2

numMod

static Number numMod(v : Number, mod : Number)
Calculates a mod b, but the result is not allowed to be negative.

Parameters:

va
modb

Returns:

a mod b if a >= 0, b + a mod b, if a < 0

Since:

3.2

numRound

static Number numRound(v : Number, intUnit : int)
Rounds v to the nearest value that can be divided by intUnit.

Parameters:

v
intUnit

Returns:

 

Since:

3.2

strDecodeBase64

static String strDecodeBase64(s : String)
Returns the result of decoding s from its base-64 equivalent.

Parameters:

s

Returns:

 

Since:

3.2

strEmpty

static boolean strEmpty(s : String)
Returns whether s is null or an empty string.

Parameters:

s

Returns:

 

Since:

3.2

strEncodeBase64

static String strEncodeBase64(s : String)
Returns the result of encoding s to its base-64 equivalent.

Parameters:

s

Returns:

 

Since:

3.2

strEndsWith

static boolean strEndsWith(s : String, strTest : String)
Returns whether s ends with strTest.

Parameters:

s
strTest

Returns:

 

Since:

3.2

strEscapeHTML

static String strEscapeHTML(s : String)
Returns s with the following four characters replaced by their escaped equivalent: & < > ". This method also replaces any character that is not a valid XML character (valid character codes are: 0x09, 0x0A, 0x0D, 0x20-0xD7FF, 0xE000-0xFFFD, 0x10000-0x10FFFF) with "\uXX" where XX is the unicode hex value of the character.

Parameters:

s

Returns:

 

Since:

3.2

strEscapeJSON

static String strEscapeJSON(str : String)
Returns str appropriately formatted and escaped for use as a JSON string. If evaluated via window.eval, the return from this method will be an exact match of the input.

Parameters:

str

Returns:

 

Since:

3.6

strTrim

static String strTrim(s : String)
Returns s trimmed of trailing and leading spaces (anything matching the regexp /\s/).

Parameters:

s

Returns:

 

Since:

3.2

strTruncate

static String strTruncate(s : String, intMax : int, strEllipsis : String, fltPos : Number)
Limits s to length intMax by placing an ellipsis in values that are too long.

Parameters:

s
intMaxthe maximum length of the string returned by this method.
strEllipsisthe ellipsis to use. "..." is used by default.
fltPosthe placement of the ellipsis as a value between 0 and 1. 1, the default, means that the ellipsis comes at the end of the truncated string. Other values mean that the head and tail of the string will be returned with the ellipsis somewhere in the middle.

Returns:

 

Since:

3.2

jsx3.util

class Collection

jsx3.util.Collection

class Collection
Deprecated. Subsumed by jsx3.util.List.

See Also:

jsx3.util.List

jsx3.util

class DateFormat

Object
->jsx3.lang.Object
  ->jsx3.util.DateFormat

class DateFormat
extends jsx3.lang.Object
Formats and parses dates according to a token-based string format. This class is fully localized.

An instance of this class is defined by its format, which is a string conforming to the following syntax: The following tokens are supported: Each token has a type, which determines how it is formatted and parsed. The token types are:

Since:

3.2

Field Summary
static int
Type for a full-length localized date or time format.
static int
Type for a long localized date or time format.
static int
Type for a medium-length localized date or time format.
static int
Type for a short localized date or time format.
Constructor Summary
void
init(strFormat : String, objLocale : jsx3.util.Locale)
The instance initializer.
Method Summary
String
format(objDate : Number | Object | Date)
Formats a date according to this date format.
static jsx3.util.DateFormat
getDateInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a date format localized for a particular locale.
static jsx3.util.DateFormat
getDateTimeInstance(intDateType : int, intTimeType : int, objLocale : jsx3.util.Locale)
Returns a date and time format localized for a particular locale.
String
Returns the format passed to the constructor.
jsx3.util.Locale
static jsx3.util.DateFormat
getTimeInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a time format localized for a particular locale.
int
getTimeZoneOffset(objDate : Date)
Returns the timezone offset of this date format.
Date
parse(strDate : String)
Parses a string according to this date format and returns the resulting date.
void
void
setTimeZoneOffset(intMinutes : int)
Sets the timezone offset of this date format.
String
Returns a string representation of this date format.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

FULL

static final int FULL
Type for a full-length localized date or time format.

LONG

static final int LONG
Type for a long localized date or time format.

MEDIUM

static final int MEDIUM
Type for a medium-length localized date or time format.

SHORT

static final int SHORT
Type for a short localized date or time format.
Constructor Detail

init

void init(strFormat : String, objLocale : jsx3.util.Locale)
The instance initializer. Instances of this class are immutable.

Parameters:

strFormatthe date format.
objLocalethe locale with which to format and parse dates. If this parameter is not provided the default system locale is used.

Throws:

{jsx3.lang.Exception}if strFormat cannot be parsed.

See Also:

Method Detail

format

String format(objDate : Number | Object | Date)
Formats a date according to this date format.

Parameters:

objDatethe date to format.

Returns:

the formatted date.  

getDateInstance

static jsx3.util.DateFormat getDateInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a date format localized for a particular locale.

Parameters:

intTypeSHORT, MEDIUM, LONG, or FULL
objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getDateTimeInstance

static jsx3.util.DateFormat getDateTimeInstance(intDateType : int, intTimeType : int, objLocale : jsx3.util.Locale)
Returns a date and time format localized for a particular locale.

Parameters:

intDateTypeSHORT, MEDIUM, LONG, or FULL
intTimeTypeSHORT, MEDIUM, LONG, or FULL
objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getFormat

String getFormat()
Returns the format passed to the constructor.

Returns:

 

getLocale

jsx3.util.Locale getLocale()

Returns:

 

getTimeInstance

static jsx3.util.DateFormat getTimeInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a time format localized for a particular locale.

Parameters:

intTypeSHORT, MEDIUM, LONG, or FULL
objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getTimeZoneOffset

int getTimeZoneOffset(objDate : Date)
Returns the timezone offset of this date format. This is the difference between GMT and the local time of this date format, in minutes. For example, Pacific Standard Time is -480 (-08h * 60). If the timezone offset has been set explicitly with setTimeZoneOffset(), that value is returned.

Since the timezone offset may change over the year for Daylight Savings Time, this method takes a Date argument, objDate. All dates are created with the timezone offset of the host browser's timezone, adjusted for Daylight Savings Time. Therefore, if the timezone offset of this date format has not been set explicitly, the timezone offset is determined from the objDate parameter, or, if that is not provided, from the current time.

Parameters:

objDatethe date for which to return the timezone offset.

Returns:

the timezone offset in minutes.  

parse

Date parse(strDate : String)
Parses a string according to this date format and returns the resulting date. If strDate does not conform to this date format, an exception is thrown.

The default date for the purposes of this method is 1-Jan-1970 12:00AM, local time. If any date fields are omitted from this format, the date returned by this method will inherit those fields from the default date.

Parameters:

strDatethe string to parse.

Throws:

{jsx3.lang.Exception}if strDate cannot be parsed according to this format.

Returns:

the parsed date. 

setLocale

void setLocale(objLocale : jsx3.util.Locale)

Parameters:

objLocale

setTimeZoneOffset

void setTimeZoneOffset(intMinutes : int)
Sets the timezone offset of this date format. The default value is the value for the local time.

Parameters:

intMinutesthe timezone offset in minutes.

See Also:


toString

String toString()
Returns a string representation of this date format.

Returns:

 

Overrides:


jsx3.util

class Dojo

Object
->jsx3.lang.Object
  ->jsx3.util.Dojo

class Dojo
extends jsx3.lang.Object
Provides the ability to load the Dojo JavaScript library.

See Also:

jsx3.gui.DojoWidget, jsx3.xml.DojoDataStore

Field Summary
static jsx3.util.EventDispatcher
A bridge to Dojo's publish/subscribe hub.
Method Summary
static void
Returns the resolved path to Dojo or a file within Dojo.
static boolean
Returns whether Dojo has been loaded.
static void
Loads the Dojo JavaScript library.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

hub

static jsx3.util.EventDispatcher hub
A bridge to Dojo's publish/subscribe hub. Events on the Dojo hub can be subscribed to through this instance. Events can also be published through this bridge, and they will be broadcast on the Dojo hub. Dojo.load() must be called before this object can be used.
Method Detail

getPath

static void getPath(s : String)
Returns the resolved path to Dojo or a file within Dojo. Dojo is assumed to be installed in the directory dojo-toolkit/ as a peer of JSX/. This location may be overridden by setting the jsx_dojo deployment parameter.

Parameters:

sthe relative path of a Dojo resource.

isLoaded

static boolean isLoaded()
Returns whether Dojo has been loaded.

Returns:

 

load

static void load()
Loads the Dojo JavaScript library. Dojo must be installed at URI jsx:/../dojo-toolkit or the jsx_dojo deployment parameter must be set to the location where Dojo is installed.

jsx3.util

interface EventDispatcher

jsx3.util.EventDispatcher

All Known Implementing Classes:

jsx3.EVT, jsx3.amp.Engine, jsx3.amp.ExtPoint, jsx3.amp.PlugIn, jsx3.amp.Resource, jsx3.amp.util.Prefs, jsx3.amp.util.PrefsPane, jsx3.amp.util.Wizard, jsx3.amp.util.WizardPane, jsx3.app.Cache, jsx3.app.DOM, jsx3.app.Model, jsx3.app.Server, jsx3.chart.AreaChart, jsx3.chart.AreaSeries, jsx3.chart.Axis, jsx3.chart.BCChart, jsx3.chart.BCSeries, jsx3.chart.BarChart, jsx3.chart.BarSeries, jsx3.chart.BubbleSeries, jsx3.chart.CartesianChart, jsx3.chart.CategoryAxis, jsx3.chart.Chart, jsx3.chart.ChartComponent, jsx3.chart.ChartLabel, jsx3.chart.ColumnChart, jsx3.chart.ColumnSeries, jsx3.chart.GridLines, jsx3.chart.Legend, jsx3.chart.LineChart, jsx3.chart.LineSeries, jsx3.chart.LinearAxis, jsx3.chart.LogarithmicAxis, jsx3.chart.PieChart, jsx3.chart.PieSeries, jsx3.chart.PlotChart, jsx3.chart.PlotSeries, jsx3.chart.PointSeries, jsx3.chart.RadialChart, jsx3.chart.Series, jsx3.gui.Block, jsx3.gui.BlockX, jsx3.gui.Button, jsx3.gui.CDF, jsx3.gui.CheckBox, jsx3.gui.ColorPicker, jsx3.gui.Column, jsx3.gui.DatePicker, jsx3.gui.Dialog, jsx3.gui.DojoWidget, jsx3.gui.Grid, jsx3.gui.HotKey, jsx3.gui.IFrame, jsx3.gui.Image, jsx3.gui.ImageButton, jsx3.gui.LayoutGrid, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Matrix.Column, jsx3.gui.Menu, jsx3.gui.NumberInput, jsx3.gui.Painted, jsx3.gui.RadioButton, jsx3.gui.Select, jsx3.gui.Slider, jsx3.gui.Sound, jsx3.gui.Splitter, jsx3.gui.Stack, jsx3.gui.StackGroup, jsx3.gui.Tab, jsx3.gui.TabbedPane, jsx3.gui.Table, jsx3.gui.Template.Block, jsx3.gui.TextBox, jsx3.gui.TimePicker, jsx3.gui.ToolbarButton, jsx3.gui.Tree, jsx3.gui.Window, jsx3.gui.WindowBar, jsx3.lang.ClassLoader, jsx3.net.Form, jsx3.net.Request, jsx3.net.Service, jsx3.util.Job, jsx3.util.JobGraph, jsx3.vector.Block, jsx3.xml.CDF.Document, jsx3.xml.Document, jsx3.xml.XslDocument

interface EventDispatcher
An Event Dispatcher mixin interface, adds the ability to register event listeners and dispatch events to those listeners.

(Deprecated) Classes that implement this mixin must also implement a method getServer(), which returns the server in which to look for JSX ids.

Since:

3.0

Field Summary
static void
Method Summary
int
publish(objEvent : Object)
Publishes an event to all subscribed objects.
void
subscribe(strEventId : String | Array<String>, objHandler : Object | String | function, objFunction : function | String)
Subscribes an object or function to a type of event published by this object.
void
unsubscribe(strEventId : String | Array<String>, objHandler : Object | String | function)
Unsubscribe an object or function from an event published by this object.
void
unsubscribeAll(strEventId : String)
Unsubscribes all subscribed objects to a type of event published by this object.
Field Detail

SUBJECT_ALL

static final ? SUBJECT_ALL
Method Detail

publish

int publish(objEvent : Object)
Publishes an event to all subscribed objects.

Parameters:

objEventthe event, should have at least a field 'subject' that is the event id, another common field is 'target' (target will default to this instance)

Throws:

{jsx3.lang.IllegalArgumentException}objEvent is not an object with a subject property

Returns:

the number of listeners to which the event was broadcast 

subscribe

void subscribe(strEventId : String | Array<String>, objHandler : Object | String | function, objFunction : function | String)
Subscribes an object or function to a type of event published by this object.

As of version 3.4 a string value for objHandler is deprecated.

Parameters:

strEventIdthe event type(s).
objHandlerif an object, the instance to notify of events (objFunction is required); if a string, the JSX id of the instance to notify of events (objFunction is required), must exist in the same Server; if a function, the function to call to notify of events (objFunction ignored)
objFunctionif objHandler is a string or object then the function to call on that instance. either a function or a string that is the name of a method of the instance

Throws:

{jsx3.lang.IllegalArgumentException}if objHandler/objFunction are not a valid combination of types

unsubscribe

void unsubscribe(strEventId : String | Array<String>, objHandler : Object | String | function)
Unsubscribe an object or function from an event published by this object.

As of version 3.4 a string value for objHandler is deprecated.

Parameters:

strEventIdthe event type(s).
objHandlerthe value of objHandler passed to subscribe

unsubscribeAll

void unsubscribeAll(strEventId : String)
Unsubscribes all subscribed objects to a type of event published by this object.

Parameters:

strEventIdthe event type

jsx3.util

class GNode

Object
->jsx3.util.GNode

Direct Known Subclasses:

jsx3.util.Job

class GNode
extends Object
No description provided.

Since:

3.6

Constructor Summary
void
init(id : String | Number)
The instance initializer.
Method Summary
boolean
add(objNode : ?)
Adds objNode as a child of this node.
boolean
del(objNode : ?)
Removes objNode as a child of this node.
Array<GNode>
Returns the child nodes of this node.
Graph
Returns the graph that this node belongs to, if any.
String | Number
id()
This function returns the unique ID of this node.
Array<GNode>
up()
Returns the parent nodes of this node.
Methods Inherited From Object
toString
Constructor Detail

init

void init(id : String | Number)
The instance initializer.

Parameters:

id
Method Detail

add

boolean add(objNode : ?)
Adds objNode as a child of this node. The node can only be added if both nodes already belong to the same graph or neither node belongs to a graph.

Parameters:

objNode

Returns:

whether the node was added.  

del

boolean del(objNode : ?)
Removes objNode as a child of this node.

Parameters:

objNode

Returns:

whether the node was removed.  

down

Array<GNode> down()
Returns the child nodes of this node.

Returns:

 

graph

Graph graph()
Returns the graph that this node belongs to, if any.

Returns:

 

id

String | Number id()
This function returns the unique ID of this node. Subclasses of this class are expected to provide their own implementation of this method. However, this implementation also generates unique IDs.

Returns:

 

up

Array<GNode> up()
Returns the parent nodes of this node.

Returns:

 

jsx3.util

class Graph

Object
->jsx3.util.Graph

class Graph
extends Object
No description provided.

Since:

3.6

Constructor Summary
void
The instance initializer.
Method Summary
boolean
add(objNode : GNode)
Adds a sub-graph to this graph.
boolean
del(objNode : GNode)
Removes a single node from this graph.
GNode
node(id : String | Number)
Returns a node by its ID.
Array<GNode>
Returns all the nodes of this graph.
Array<GNode>
Returns all the root nodes of this graph.
int
Returns the number of nodes in this graph.
Methods Inherited From Object
toString
Constructor Detail

init

void init()
The instance initializer.
Method Detail

add

boolean add(objNode : GNode)
Adds a sub-graph to this graph. objNode is the root of the directed sub-graph.

Parameters:

objNode

Returns:

whether the node was added.  

del

boolean del(objNode : GNode)
Removes a single node from this graph.

Parameters:

objNode

Returns:

whether the node was removed.  

node

GNode node(id : String | Number)
Returns a node by its ID.

Parameters:

id

Returns:

 

nodes

Array<GNode> nodes()
Returns all the nodes of this graph.

Returns:

 

roots

Array<GNode> roots()
Returns all the root nodes of this graph. A root node has no parent nodes.

Returns:

 

size

int size()
Returns the number of nodes in this graph.

Returns:

 

jsx3.util

interface Iterator

jsx3.util.Iterator

abstract interface Iterator
An interface that defines an object that can be iterated over.

Since:

3.2

Method Summary
abstract boolean
Returns whether there are more elements remaining in this iterator.
abstract Object
Returns the next element in this iterator.
abstract void
Removes the last object returned by next() from the source backing this iterator.
Method Detail

hasNext

abstract boolean hasNext()
Returns whether there are more elements remaining in this iterator.

Returns:

 

next

abstract Object next()
Returns the next element in this iterator.

Returns:

 

remove

abstract void remove()
Removes the last object returned by next() from the source backing this iterator.

jsx3.util

class Job

Object
->jsx3.util.GNode
  ->jsx3.util.Job

All Implemented Interfaces:

jsx3.util.EventDispatcher

class Job
extends jsx3.util.GNode
No description provided.

Since:

3.6

Field Summary
static int
Value that the run() method may return to indicate that the job has finished and any dependent jobs should be run immediately.
static String
Event subject published when this job finishes.
static int
Value for the state property indicating that this job has finished.
static int
Value that the run() method may return to indicate that the job should be put back on the waiting job queue.
static int
Value that the run() method may return to indicate that the job has finished and any dependent jobs should be run after breaking the JavaScript stack with window.setTimeout().
static int
Value that the run() method may return to indicate that the job will not finish until the finish() method is called.
static int
Value for the state property indicating that this job has not yet finished.
Constructor Summary
void
init(id : String, fctRun : ?)
The instance initializer.
Method Summary
void
A job should call this method on itself if its run() method returns WAIT to communicate to the job manager that it has finished.
int
run()
Runs the job.
void
Returns the job state.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.util.GNode
add, del, down, graph, id, up
Methods Inherited From Object
toString
Field Detail

DONE

static final int DONE
Value that the run() method may return to indicate that the job has finished and any dependent jobs should be run immediately.

FINISH

static final String FINISH
Event subject published when this job finishes.

FINISHED

static final int FINISHED
Value for the state property indicating that this job has finished.

PUSH

static final int PUSH
Value that the run() method may return to indicate that the job should be put back on the waiting job queue.

SLEEP

static final int SLEEP
Value that the run() method may return to indicate that the job has finished and any dependent jobs should be run after breaking the JavaScript stack with window.setTimeout().

WAIT

static final int WAIT
Value that the run() method may return to indicate that the job will not finish until the finish() method is called.

WAITING

static final int WAITING
Value for the state property indicating that this job has not yet finished.
Constructor Detail

init

void init(id : String, fctRun : ?)
The instance initializer.

Parameters:

idthe unique job id. If this parameter is not provided, a suitable unique value is generated.
fctRun
Method Detail

finish

void finish()
A job should call this method on itself if its run() method returns WAIT to communicate to the job manager that it has finished.

See Also:


run

int run()
Runs the job. This method should be overridden for any job that wants to perform some action.

Returns:

WAIT, DONE, or SLEEP

See Also:

, ,

state

void state()
Returns the job state.

Returns:

WAITING or FINISHED

See Also:

,

jsx3.util

class JobGraph

Object
->jsx3.util.JobGraph

All Implemented Interfaces:

jsx3.util.EventDispatcher

class JobGraph
extends Object
No description provided.

Since:

3.6

Field Summary
static String
Event subject published when the job graph empties.
static String
Event subject published when a job is finished.
Constructor Summary
void
The instance initializer.
Method Summary
void
addJob(objJob : jsx3.util.Job, preReqs : String | Array<String>, postReqs : String | Array<String>)
Add a job to this manager.
void
addPrereq(objJob : String | jsx3.util.Job, preJob : String | jsx3.util.Job)
Adds a prerequisite to the job with id jobId.
void
Returns the number of jobs that have finished.
void
insertJob(newJob : ?, referenceJob : ?)
Inserts newJob as a graph root and adds all children of referenceJob as children of newJob.
boolean
void
Pauses this job manager.
void
Resets this job manager.
void
Starts this job manager.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From Object
toString
Field Detail

DONE

static String DONE
Event subject published when the job graph empties.

RAN_JOB

static String RAN_JOB
Event subject published when a job is finished.
Constructor Detail

init

void init()
The instance initializer.
Method Detail

addJob

void addJob(objJob : jsx3.util.Job, preReqs : String | Array<String>, postReqs : String | Array<String>)
Add a job to this manager. If the manager is running and no prerequisites are specified then the job is run immediately.

Parameters:

objJobthe job to add.
preReqsthe ids of all the jobs that must finish before the job is run.
postReqsthe ids of all the jobs that must must not run before the job is run.

Throws:

{Error}if a job with the same id as objJob is currently waiting in this manager or if any prerequisite id does not correspond to a job not currently waiting in this job manager.

addPrereq

void addPrereq(objJob : String | jsx3.util.Job, preJob : String | jsx3.util.Job)
Adds a prerequisite to the job with id jobId.

Parameters:

objJobthe job or its ID to which to add the prerequisite.
preJobthe job or its ID that is a prerequisite of job objJob.

Throws:

{Error}if either parameter refers to a job not currently waiting in this job manager.

doneCt

void doneCt()
Returns the number of jobs that have finished.

insertJob

void insertJob(newJob : ?, referenceJob : ?)
Inserts newJob as a graph root and adds all children of referenceJob as children of newJob. This method is typically called in the "onDone" of referenceJob, when it creates newJob and wants newJob to run before any dependent jobs of itself (referenceJob).

Parameters:

newJob
referenceJob

isRunning

boolean isRunning()

Returns:

 

pause

void pause()
Pauses this job manager.

reset

void reset()
Resets this job manager.

start

void start()
Starts this job manager.

jsx3.util

class List

Object
->jsx3.lang.Object
  ->jsx3.util.List

class List
extends jsx3.lang.Object
An object-oriented version of the built-in JavaScript Array class.

Note that methods such as indexOf and remove compare objects with the strict equality operators (=== and !==). Therefore, for the purposes of this class 1 and "1" are not equal.

Since:

3.2

Constructor Summary
void
init(a : int | Array | jsx3.util.List, bLive : boolean)
The instance initializer.
Method Summary
void
add(objElm : Object, intAt : int)
void
addAll(a : Array | jsx3.util.List, intAt : int)
void
Removes all elements from this list.
jsx3.util.List
Returns a copy of this list.
boolean
contains(objElm : Object)
boolean
equals(l : Object)
Returns true if this list and l have the same length and this.get(n) = l.get(n) for all n.
jsx3.util.List
filter(fctFilter : Function)
Creates a new list with the filtered contents of this list.
Object
get(intIndex : int)
void
Deprecated. Use the jsx3.util.Iterator interface instead.
void
getItem(intIndex : ?)
Deprecated. Use get() instead.
void
Deprecated. Use size() instead.
void
Deprecated. Use the jsx3.util.Iterator interface instead.
int
indexOf(objElm : Object, intStartAt : int)
Returns the index of the first occurrence of objElm in this list.
jsx3.util.Iterator
int
lastIndexOf(objElm : Object, intStartAt : int)
Returns the index of the last occurrence of objElm in this list.
jsx3.util.List | Object
map(fctMapper : Function, bExpand : boolean, bObject : boolean)
Creates a new list with the mapped contents of this array.
void
move(intIndex : ?)
Deprecated. Use the jsx3.util.Iterator interface instead.
void
Deprecated. Use the jsx3.util.Iterator interface instead.
void
remove(objElm : Object)
Removes the first occurrence of objElm in this list.
Object | jsx3.util.List<Object>
removeAt(intStart : int, intEnd : int)
Removes a single or a range of elements from this list.
void
Deprecated. Use the jsx3.util.Iterator interface instead.
void
set(intIndex : int, objElm : Object)
int
List
slice(intStart : int, intEnd : int)
Returns a section of this list as another list.
void
sort(fctComparator : Function)
Sorts this list.
Array
toArray(bLive : boolean)
Returns a copy of this list as an array.
static jsx3.util.List
If a is already an instance of this class, this method returns a.
Methods Inherited From jsx3.lang.Object
eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(a : int | Array | jsx3.util.List, bLive : boolean)
The instance initializer. Creates a new list. If a is a number, the list is initialized with that size. If a is an array or list, the contents of a are copied into the new list.

Parameters:

a
bLive
Method Detail

add

void add(objElm : Object, intAt : int)

Parameters:

objElm
intAt

addAll

void addAll(a : Array | jsx3.util.List, intAt : int)

Parameters:

a
intAt

Throws:

{jsx3.lang.IllegalArgumentException}if a is not a list or array.

clear

void clear()
Removes all elements from this list.

clone

jsx3.util.List clone()
Returns a copy of this list.

Returns:

 

Overrides:


contains

boolean contains(objElm : Object)

Parameters:

objElmthe item to find

Returns:

 

equals

boolean equals(l : Object)
Returns true if this list and l have the same length and this.get(n) = l.get(n) for all n.

Parameters:

l

Returns:

 

Overrides:


filter

jsx3.util.List filter(fctFilter : Function)
Creates a new list with the filtered contents of this list. The fctFilter parameter defines the filtering function.

Parameters:

fctFiltera function that is called once for each item in this array and returns true if the item should be included in the filtered list. The signature of this function is function(item : Object) : boolean.

Returns:

 

get

Object get(intIndex : int)

Parameters:

intIndex

Returns:

 

getIndex

void getIndex()
Deprecated. Use the jsx3.util.Iterator interface instead.

getItem

void getItem(intIndex : ?)
Deprecated. Use get() instead.

Parameters:

intIndex

getLength

void getLength()
Deprecated. Use size() instead.

hasNext

void hasNext()
Deprecated. Use the jsx3.util.Iterator interface instead.

indexOf

int indexOf(objElm : Object, intStartAt : int)
Returns the index of the first occurrence of objElm in this list. Comparisons are performed with strict equals (===).

Parameters:

objElmthe item to find
intStartAt

Returns:

the index of the found object or -1 if not found.  

iterator

jsx3.util.Iterator iterator()

Returns:

 

lastIndexOf

int lastIndexOf(objElm : Object, intStartAt : int)
Returns the index of the last occurrence of objElm in this list. Comparisons are performed with strict equals (===).

Parameters:

objElmthe item to find
intStartAt

Returns:

the index of the found object or -1 if not found  

map

jsx3.util.List | Object map(fctMapper : Function, bExpand : boolean, bObject : boolean)
Creates a new list with the mapped contents of this array. The fctMapper parameter defines the mapping function.

This method has four modes corresponding to the four possible values for {bExpand, bObject}:
  • {false, false} (default) – the filtering function takes an item in this list and returns a single object value which will take the place of the item in the mapped result.
  • {true, false} – the filtering function takes an item in this list and returns a single object value or an array of values, all of which will be inserted into the mapped result at the index of the item.
  • {false, true} – the filtering function takes an item in this list and returns an array with exactly two values, which become a name/value pair in the mapped result.
  • {true, true} – the filtering function takes an item in this list and returns an array with zero or an even number of items, which become name/value pairs in the mapped result.

Parameters:

fctMappera function that is called once for each item in this array and returns the mapped value. The signature of this function depends on the values for the bExpand and bObject parameters.
bExpandif true, the resulting mapped array or object may any number of values corresponding to each item in this list. Otherwise, it will have exactly one value for each item in this list.
bObjectif true, this array is mapped to an object with property name/value pairs. Otherwise this array is mapped to another array.

Returns:

a list if the bObject parameter is null or false, otherwise an Object.  

move

void move(intIndex : ?)
Deprecated. Use the jsx3.util.Iterator interface instead.

Parameters:

intIndex

next

void next()
Deprecated. Use the jsx3.util.Iterator interface instead.

remove

void remove(objElm : Object)
Removes the first occurrence of objElm in this list.

Parameters:

objElmthe object to remove

Returns:

the removed object or null if no object was removed  

removeAt

Object | jsx3.util.List<Object> removeAt(intStart : int, intEnd : int)
Removes a single or a range of elements from this list.

Parameters:

intStart
intEnd

Returns:

the removed object or null if no object was removed  

reset

void reset()
Deprecated. Use the jsx3.util.Iterator interface instead.

set

void set(intIndex : int, objElm : Object)

Parameters:

intIndex
objElm

size

int size()

Returns:

 

slice

List slice(intStart : int, intEnd : int)
Returns a section of this list as another list. The returned section is a copy of this list and is not affected by subsequent changes to this list.

Parameters:

intStart
intEnd

Returns:

 

sort

void sort(fctComparator : Function)
Sorts this list.

Parameters:

fctComparator

toArray

Array toArray(bLive : boolean)
Returns a copy of this list as an array.

Parameters:

bLiveif true, then the returned array is the actual backing array of this list.

Returns:

 

wrap

static jsx3.util.List wrap(a : Array | jsx3.util.List)
If a is already an instance of this class, this method returns a. If a is an array, this method returns a new List instance backed by a.

Parameters:

a

Throws:

{jsx3.lang.IllegalArgumentException}if a is not a list or array.

Returns:

 

jsx3.util

class Locale

Object
->jsx3.lang.Object
  ->jsx3.util.Locale

class Locale
extends jsx3.lang.Object
Represents a region of the world. Other classes may be localized, meaning that their behavior depends on their assigned locale.

Since:

3.2

Field Summary
static jsx3.util.Locale
Locale for English (country unspecified).
static jsx3.util.Locale
Locale for United Kingdom.
static jsx3.util.Locale
Locale for United States of America.
Constructor Summary
void
init(strLanguage : String, strCountry : String)
The instance initializer.
Method Summary
boolean
equals(obj : Object)
Returns true if obj is equal to this locale.
String
Returns the uppercase two letter ISO-3166 country code.
String
Returns the country of this locale, localized for objLocale.
String
Returns the language of this locale, localized for objLocale.
String
Returns the language and country of this locale, localized for objLocale.
String
Returns the lowercase two letter ISO-639 language code.
String
static jsx3.util.Locale
valueOf(strKey : String)
Returns a locale instance represented by strKey.
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ENGLISH

static jsx3.util.Locale ENGLISH
Locale for English (country unspecified).

UK

static jsx3.util.Locale UK
Locale for United Kingdom.

US

static jsx3.util.Locale US
Locale for United States of America.
Constructor Detail

init

void init(strLanguage : String, strCountry : String)
The instance initializer.

Parameters:

strLanguagethe lowercase two letter ISO-639 language code.
strCountrythe uppercase two letter ISO-3166 country code.
Method Detail

equals

boolean equals(obj : Object)
Returns true if obj is equal to this locale.

Parameters:

obj

Returns:

 

Overrides:


getCountry

String getCountry()
Returns the uppercase two letter ISO-3166 country code.

Returns:

 

getDisplayCountry

String getDisplayCountry(objLocale : jsx3.util.Locale)
Returns the country of this locale, localized for objLocale.

Parameters:

objLocalethe locale in which to format the country. If this parameter is not provided, the system locale is used.

Returns:

 

getDisplayLanguage

String getDisplayLanguage(objLocale : jsx3.util.Locale)
Returns the language of this locale, localized for objLocale.

Parameters:

objLocalethe locale in which to format the language. If this parameter is not provided, the system locale is used.

Returns:

 

getDisplayName

String getDisplayName(objLocale : jsx3.util.Locale)
Returns the language and country of this locale, localized for objLocale.

Parameters:

objLocalethe locale in which to format the language and country. If this parameter is not provided, the system locale is used.

Returns:

 

getLanguage

String getLanguage()
Returns the lowercase two letter ISO-639 language code.

Returns:

 

toString

String toString()

Returns:

 

Overrides:


valueOf

static jsx3.util.Locale valueOf(strKey : String)
Returns a locale instance represented by strKey.

Parameters:

strKeythe locale key, ll_CC, where ll is the two letter language code and CC is the two letter country code.

Returns:

 

jsx3.util

class Logger

Object
->jsx3.lang.Object
  ->jsx3.util.Logger

class Logger
extends jsx3.lang.Object
A Logger is used to log messages about a particular component of an application.

Loggers are organized hierarchically according to name, descending from the root logger, "global." A period denotes levels in the hierarchy. For example, global is the parent of com is the parent of com.tibco is the parent of com.tibco.gi, etc.

A Logger has a level that determines what severity of messages will be handled. Messages with severity below the level of the Logger will be ignored. If the level of a Logger is not explicitly defined, the level is inherited from its parent.

A Logger can have any number of handlers, each of which can output a log message to a different place. By default a logger will also forward log messages to the handlers of its ancestors, although this can be disabled per Logger.

A typical usage pattern is to create a Logger for each class, setting it as a private static field of that class, as in the following code example:
jsx3.Class.defineClass('eg.Thing', null, null, function(Thing, Thing_prototype) {
  
  // import jsx3.util.Logger
  var Logger = jsx3.util.Logger;
  // create Logger for this class
  Thing._LOG = Logger.getLogger(Thing.jsxclass.getName());
  Thing.prototype.init = function(arg1, arg2, arg2) {
    Thing._LOG.debug("received args: " + arg1 + ", " + arg2 + ", " + arg3);
    if (isNaN(arg1)) {
      Thing._LOG.warn("arg1 is not a number, setting to 0");
      this._one = 0;
    } else {
      this._one = arg1;
    }
  };
});
If the creation of the log message is expensive (depending on the implementation, toString() can be expensive), isLoggable() can be used to check whether the log statement will actually be handled before creating the log message:
if (LOG.isLoggable(jsx3.util.Logger.INFO))
  LOG.info(anObject.toString());

Since:

3.1

Nested Class Summary
jsx3.util.Logger.AlertHandler
Handles a logging record by sending it to a JavaScript alert.
jsx3.util.Logger.ConsoleHandler
Handles a logging record by sending it to the Firebug console.
jsx3.util.Logger.FormatHandler
A subclass of Handler that includes functionality for formatting logging records as human-readable strings.
jsx3.util.Logger.Handler
The base logging handler class.
jsx3.util.Logger.Manager
Manager class for the logging system.
jsx3.util.Logger.MemoryHandler
A simple Handler class that stores a rotating cache of log records in memory.
jsx3.util.Logger.Record
Record bean that stores information about a logging message.
Field Summary
static int
Level indicating debug message.
static int
Level indicating error.
static int
Level indicating fatal error.
static jsx3.util.Logger
Convenient access to jsx3.util.Logger.getLogger('global').
static int
Level indicating informational message.
static int
Set the level of a Logger or Handler to this value to ignore all messages.
static int
Level indicating trace message.
static int
Level indicating warning.
Method Summary
void
Add a handler to this Logger.
void
debug(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level DEBUG.
static void
doLog(strErrorNumber : String, strMessage : String, PRIORITY : int, bTrace : boolean)
Deprecated. use either jsx3.log or Logger.log()
void
error(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level ERROR.
static String
errorToString(error : ?)
Deprecated.
void
fatal(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level FATAL.
int
Returns the effective level of this Logger, which is either the explicitly set value of this Logger or the effective level of this Logger's parent Logger.
int
Returns the level of this Logger.
static Object
Deprecated. returns an empty array
static jsx3.util.Logger
getLogger(strName : String)
Returns an Logger instance.
static void
Deprecated. use Logger.isLoggable()
String
Returns the name of this Logger.
jsx3.util.Logger
Returns the parent Logger of this Logger.
boolean
Returns whether this Logger will publish log messages to the handlers of its parent Logger.
void
info(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level INFO.
boolean
isLoggable(intLevel : int)
Returns true if a log message sent to this logger at level intLevel will be forwarded on to the handlers of this logger.
static String
levelAsString(intLevel : int)
Returns the string (English) representation of a level value.
void
log(intLevel : int, strMessage : String, strArgs : Array<String> | String...)
Log a message.
void
logError(intLevel : int, strMessage : String, objError : jsx3.lang.Exception)
Log an exception.
static void
logError(e : Object, PRIORITY : int)
Deprecated. use instance method Logger.logError()
void
logStack(intLevel : int, strMessage : String, intSkip : int)
Log the current stack with a message.
void
Remove a handler from this Logger.
static void
Deprecated. no effect
void
setLevel(intLevel : int)
Sets the level of this Logger.
void
Sets the parent Logger of this Logger.
void
Sets whether this Logger will publish log messages to the handlers of its parent Logger.
static Object
Deprecated. Returns empty string.
void
trace(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level TRACE.
void
warn(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level WARN.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Field Detail

DEBUG

static final int DEBUG
Level indicating debug message.

ERROR

static final int ERROR
Level indicating error.

FATAL

static final int FATAL
Level indicating fatal error.

GLOBAL

static jsx3.util.Logger GLOBAL
Convenient access to jsx3.util.Logger.getLogger('global').

INFO

static final int INFO
Level indicating informational message.

OFF

static final int OFF
Set the level of a Logger or Handler to this value to ignore all messages.

TRACE

static final int TRACE
Level indicating trace message.

WARN

static final int WARN
Level indicating warning.
Method Detail

addHandler

void addHandler(objHandler : jsx3.util.Logger.Handler)
Add a handler to this Logger.

Parameters:

objHandler

debug

void debug(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level DEBUG. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

doLog

static void doLog(strErrorNumber : String, strMessage : String, PRIORITY : int, bTrace : boolean)
Deprecated. use either jsx3.log or Logger.log()
Called by several foundation classes when non-critical errors occur. Basically allows the error to be saved to memory and be queried by the application developer for more-specific information about why a given request may have failed. Sends a log message to the global Logger. Attempts to convert the PRIORITY argument to a valid value for Logger, defaults to INFO.

Parameters:

strErrorNumberarbitrary identifier passed by the calling function to track the specific location of the error
strMessagemessage to describe the error
PRIORITYone of 1, 2 or 3, with 1 being most serious (red..orange..yellow)
bTracetrue if null; if true, the stack trace is printed, displaying the order of the call stack

See Also:

,

error

void error(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level ERROR. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

errorToString

static String errorToString(error : ?)
Deprecated.
returns a text-based version of the error log object. This is helpful when debugging a JSX application that doesn't fully initialize. In practice, if you are viewing a web page with an embedded JSX application, you can type (ctrl + o) to show the browser's 'open' dialog. From there, enter the following bit of Javascript to call this function: javascript:alert(jsx3.util.Logger.toString());

Parameters:

error

Returns:

 

fatal

void fatal(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level FATAL. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

getEffectiveLevel

int getEffectiveLevel()
Returns the effective level of this Logger, which is either the explicitly set value of this Logger or the effective level of this Logger's parent Logger.

Returns:

 

getLevel

int getLevel()
Returns the level of this Logger. This method will return null unless the level of this Logger has been explicitly set either in the configuration file or with a call to setLevel().

Returns:

 

getLog

static Object getLog()
Deprecated. returns an empty array
returns the JavaScript Array containing all non-fatal app errors trapped by various foundation classes; as a developer, you can access a specific error by simply referencing its ordinal index. This will give you a handle to the individual error object (a JavaScript object). You can then query this object for a specific property, including: code, description, priority, timestamp. So, for example, to get the timestamp for the oldest error in the log you would call: jsx3.util.Logger.getLog[0]["timestamp"]

Returns:

JavaScript Array 

getLogger

static jsx3.util.Logger getLogger(strName : String)
Returns an Logger instance. Either creates a new logger or returns a pre-existing logger of the same name. This class is a factory class so instances of Logger may not be instantiated directly. Use this method to get a handle to a logger.

Parameters:

strNamethe name of the logger to return

Returns:

 

getMinPriority

static void getMinPriority()
Deprecated. use Logger.isLoggable()
No errors will be published with priority level less than (integer greater than) this value.

getName

String getName()
Returns the name of this Logger.

Returns:

 

getParent

jsx3.util.Logger getParent()
Returns the parent Logger of this Logger. The global logger will return null from this method.

Returns:

 

getUseParentHandlers

boolean getUseParentHandlers()
Returns whether this Logger will publish log messages to the handlers of its parent Logger.

Returns:

 

info

void info(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level INFO. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

isLoggable

boolean isLoggable(intLevel : int)
Returns true if a log message sent to this logger at level intLevel will be forwarded on to the handlers of this logger.

Parameters:

intLevelthe level to test

Returns:

 

levelAsString

static String levelAsString(intLevel : int)
Returns the string (English) representation of a level value.

Parameters:

intLevela level value between FATAL and TRACE

Returns:

a string representation of the level value  

log

void log(intLevel : int, strMessage : String, strArgs : Array<String> | String...)
Log a message.

Parameters:

intLevelthe level of the message
strMessagethe message to log
strArgseither an array of or variable argument message parameters, optional argument

logError

void logError(intLevel : int, strMessage : String, objError : jsx3.lang.Exception)
Log an exception.

Parameters:

intLevelthe level of the message
strMessagethe message to log with the exception, may be null
objErrorthe exception to log

logError

static void logError(e : Object, PRIORITY : int)
Deprecated. use instance method Logger.logError()
Log all properties of an exception to the system log.

Parameters:

ethe exception object to log
PRIORITYpriority of error

logStack

void logStack(intLevel : int, strMessage : String, intSkip : int)
Log the current stack with a message.

Parameters:

intLevelthe level of the message
strMessagethe message to log, optional argument
intSkip

removeHandler

void removeHandler(objHandler : jsx3.util.Logger.Handler)
Remove a handler from this Logger.

Parameters:

objHandler

reset

static void reset()
Deprecated. no effect
Resets the system out; publishes event to the jsx3.util.Logger.ON_MESSAGE subject.

setLevel

void setLevel(intLevel : int)
Sets the level of this Logger.

Parameters:

intLevel

setParent

void setParent(objParent : jsx3.util.Logger)
Sets the parent Logger of this Logger.

Parameters:

objParent

setUseParentHandlers

void setUseParentHandlers(bUseParent : boolean)
Sets whether this Logger will publish log messages to the handlers of its parent Logger.

Parameters:

bUseParent

toString

static Object toString()
Deprecated. Returns empty string.
returns a text-based version of the error log object. This is helpful when debugging a JSX application that doesn't fully initialize. In practice, if you are viewing a web page with an embedded JSX application, you can type (ctrl + o) to show the browser's 'open' dialog. From there, enter the following bit of Javascript to call this function: javascript:alert(jsx3.util.Logger.toString());

Returns:

JavaScript Array 

Overrides:


trace

void trace(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level TRACE. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

warn

void warn(strMessage : String, strArgs : Array<String> | String... | jsx3.lang.Exception)
Log a message at level WARN. Polymorphic method honors the signature of either log() or logError() (without the first intLevel parameter).

Parameters:

strMessagethe message to log
strArgseither an array of message parameters, variable argument message parameters, or an exception; optional argument

jsx3.util

class Logger.AlertHandler

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler
    ->jsx3.util.Logger.FormatHandler
      ->jsx3.util.Logger.AlertHandler

abstract class Logger.AlertHandler
extends jsx3.util.Logger.FormatHandler
Handles a logging record by sending it to a JavaScript alert.

Method Summary
int
Returns the message interval at which the user has the opportunity to disable this handler.
void
setConfirmInterval(intInterval : int)
Sets the message interval at which the user has the opportunity to disable this handler.
Methods Inherited From jsx3.util.Logger.FormatHandler
getFormat, setFormat
Methods Inherited From jsx3.util.Logger.Handler
getLevel, getName, handle, isLoggable, setLevel
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

getConfirmInterval

int getConfirmInterval()
Returns the message interval at which the user has the opportunity to disable this handler.

Returns:

 

setConfirmInterval

void setConfirmInterval(intInterval : int)
Sets the message interval at which the user has the opportunity to disable this handler.

Parameters:

intInterval

jsx3.util

class Logger.ConsoleHandler

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler
    ->jsx3.util.Logger.FormatHandler
      ->jsx3.util.Logger.ConsoleHandler

abstract class Logger.ConsoleHandler
extends jsx3.util.Logger.FormatHandler
Handles a logging record by sending it to the Firebug console.

Methods Inherited From jsx3.util.Logger.FormatHandler
getFormat, setFormat
Methods Inherited From jsx3.util.Logger.Handler
getLevel, getName, handle, isLoggable, setLevel
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString

jsx3.util

class Logger.FormatHandler

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler
    ->jsx3.util.Logger.FormatHandler

Direct Known Subclasses:

jsx3.app.Monitor, jsx3.util.Logger.AlertHandler, jsx3.util.Logger.ConsoleHandler

abstract class Logger.FormatHandler
extends jsx3.util.Logger.Handler
A subclass of Handler that includes functionality for formatting logging records as human-readable strings.

The following tokens are supported in the format:

Method Summary
String
Returns the format to use for formatting logging records.
void
setFormat(strFormat : String)
Sets the format to use for formatting logging records.
Methods Inherited From jsx3.util.Logger.Handler
getLevel, getName, handle, isLoggable, setLevel
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

getFormat

String getFormat()
Returns the format to use for formatting logging records.

Returns:

 

setFormat

void setFormat(strFormat : String)
Sets the format to use for formatting logging records.

Parameters:

strFormat

jsx3.util

class Logger.Handler

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler

Direct Known Subclasses:

jsx3.util.Logger.FormatHandler, jsx3.util.Logger.MemoryHandler

abstract class Logger.Handler
extends jsx3.lang.Object
The base logging handler class. Handlers receive log records from loggers and output (or ignore) them in some way.

Concrete subclasses of this class must implement the handle() method. This method defines what to do to "handle" the logging record. This method does not need to check the handler's level against the level of the record. The the logger does this before calling handle() and will not call handle() if the record's level is not severe enough.

Constructor Summary
void
init(strName : String)
Method Summary
int
Returns the level of this handler.
String
Returns the name of this Handler.
abstract void
Concrete subclasses of this class must implement this method, which defines how a log record is handled.
boolean
isLoggable(intLevel : int)
Returns true if a log message sent to this handler at level intLevel will be processed rather than ignored.
static void
Call this method to let the logging system know that a new subclass of Handler has been defined.
int
setLevel(intLevel : ?)
Sets the level of this handler.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(strName : String)

Parameters:

strNamethe name to assign this handler
Method Detail

getLevel

int getLevel()
Returns the level of this handler. May be null if no level has been specified.

Returns:

 

getName

String getName()
Returns the name of this Handler.

Returns:

 

handle

abstract void handle(objRecord : jsx3.util.Logger.Record)
Concrete subclasses of this class must implement this method, which defines how a log record is handled.

Parameters:

objRecord

isLoggable

boolean isLoggable(intLevel : int)
Returns true if a log message sent to this handler at level intLevel will be processed rather than ignored.

Parameters:

intLevelthe level to test

Returns:

 

registerHandlerClass

static void registerHandlerClass(objClass : jsx3.lang.Class)
Call this method to let the logging system know that a new subclass of Handler has been defined. Handlers may be defined in the configuration file to be lazy. The class of a lazy handler is not required to exist when the logging system initializes. However, for the lazy handler to be instantiated, this method must be called to let the logging system know that the necessary class has loaded.

Parameters:

objClassthe subclass of Handler that was defined

setLevel

int setLevel(intLevel : ?)
Sets the level of this handler.

Parameters:

intLevel

Returns:

one of FATAL to TRACE, OFF, or null  

jsx3.util

class Logger.Manager

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Manager

class Logger.Manager
extends jsx3.lang.Object
Manager class for the logging system. The singleton instance of this class is configured with the logger configuration file specified by the system environment variable jsx_logger_config, or if that is not provided, by the default configuration file located at $GI/logger.xml.

The DTD of that configuration file is as follows:
<!ELEMENT configuration (handler | logger)* >
<!ELEMENT handler (property)* >
<!ATTLIST handler name CDATA #REQUIRED
                  class CDATA #REQUIRED
                  lazy (true|false) "false"
                  require (true|false) "false"
                  level (OFF|FATAL|ERROR|WARN|INFO|DEBUG|TRACE) #IMPLIED>
<!ELEMENT logger (property | handler-ref)* >
<!ATTLIST logger name CDATA #REQUIRED
                 useParent (true|false) "true"
                 level (OFF|FATAL|ERROR|WARN|INFO|DEBUG|TRACE) #IMPLIED>
<!-- Properties allow for bean-style configuration of handlers and loggers.
     The class should have a setter method corresponding to the name of the 
     property. -->
<!ELEMENT property (EMPTY)>
<!ATTLIST property name CDATA #REQUIRED
                   value CDATA #REQUIRED
                   eval (true|false) "false">
<!ELEMENT handler-ref (EMPTY)>
<!ATTLIST handler-ref name CDATA #REQUIRED>

Method Summary
void
Add a Handler instance to this manager's registry.
void
Add a Logger instance to the manager's registry.
jsx3.util.Logger.Handler
getHandler(strName : ?)
Returns a Handler from the manager's registry by name, or null if no such Handler is registered.
Array<String>
Returns a list containing the names of all the handlers registered with this manager.
jsx3.util.Logger
getLogger(strName : ?)
Returns a Logger from this manager's registry by name, or null if no such Logger is registered.
static jsx3.util.Logger.Manager
Singleton accessor method.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Method Detail

addHandler

void addHandler(objHandler : jsx3.util.Logger.Handler)
Add a Handler instance to this manager's registry.

Parameters:

objHandler

addLogger

void addLogger(objLogger : jsx3.util.Logger)
Add a Logger instance to the manager's registry.

Parameters:

objLogger

getHandler

jsx3.util.Logger.Handler getHandler(strName : ?)
Returns a Handler from the manager's registry by name, or null if no such Handler is registered.

Parameters:

strName

Returns:

 

getHandlerNames

Array<String> getHandlerNames()
Returns a list containing the names of all the handlers registered with this manager.

Returns:

 

getLogger

jsx3.util.Logger getLogger(strName : ?)
Returns a Logger from this manager's registry by name, or null if no such Logger is registered.

Parameters:

strName

Returns:

 

getManager

static jsx3.util.Logger.Manager getManager()
Singleton accessor method.

Returns:

 

jsx3.util

class Logger.MemoryHandler

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Handler
    ->jsx3.util.Logger.MemoryHandler

class Logger.MemoryHandler
extends jsx3.util.Logger.Handler
A simple Handler class that stores a rotating cache of log records in memory.

May be configured with the bufferSize property (default 100).

Constructor Summary
void
init(strName : ?)
Instance initializer.
Method Summary
void
Clears the contents of the buffer.
int
Returns the size of the buffer.
Array<jsx3.util.Logger.Record>
getRecords(intCount : int)
Returns the contents of the record buffer.
void
Stores the log record in memory.
void
setBufferSize(intBufferSize : int)
Sets the size of the buffer.
Methods Inherited From jsx3.util.Logger.Handler
getLevel, getName, isLoggable, setLevel
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(strName : ?)
Instance initializer.

Parameters:

strName
Method Detail

clearBuffer

void clearBuffer()
Clears the contents of the buffer.

getBufferSize

int getBufferSize()
Returns the size of the buffer. This handler will store at most this many log records before discarding old ones.

Returns:

 

getRecords

Array<jsx3.util.Logger.Record> getRecords(intCount : int)
Returns the contents of the record buffer.

Parameters:

intCountthe number of records to return, the most recently added records will be returned. Pass null to get all records.

Returns:

 

handle

void handle(objRecord : jsx3.util.Logger.Record)
Stores the log record in memory. Removes the oldest record if the buffer is full.

Parameters:

objRecord

Overrides:


setBufferSize

void setBufferSize(intBufferSize : int)
Sets the size of the buffer. If this operation decreases the size of the buffer, log records may be discarded.

Parameters:

intBufferSize

jsx3.util

class Logger.Record

Object
->jsx3.lang.Object
  ->jsx3.util.Logger.Record

class Logger.Record
extends jsx3.lang.Object
Record bean that stores information about a logging message.

Constructor Summary
void
init(strMessage : String, arrParams : Array<Object>, intLevel : int, strLogger : String, arrStack : Function | Array<Function>, objError : jsx3.lang.Exception)
Instance initializer.
Method Summary
Date
Returns the current date when this record was created.
jsx3.lang.Exception
Returns the exception that this record was created with.
Function
Returns the JavaScript function that called the Logger message that created this record.
int
Returns the logging level that this record was created with.
String
Returns the name of the logger that created this record.
String
Returns the raw message of this record.
Array<Object>
Returns the message parameters of this record.
int
Returns this record's serial number.
Array<Function>
Returns the complete JavaScript stack from when this record was created.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(strMessage : String, arrParams : Array<Object>, intLevel : int, strLogger : String, arrStack : Function | Array<Function>, objError : jsx3.lang.Exception)
Instance initializer.

Parameters:

strMessage
arrParams
intLevel
strLogger
arrStack
objError
Method Detail

getDate

Date getDate()
Returns the current date when this record was created.

Returns:

 

getError

jsx3.lang.Exception getError()
Returns the exception that this record was created with. Will only be defined if this record was created through a call to Logger.logError() or similar.

Returns:

 

getFunction

Function getFunction()
Returns the JavaScript function that called the Logger message that created this record.

Returns:

 

getLevel

int getLevel()
Returns the logging level that this record was created with.

Returns:

 

getLoggerName

String getLoggerName()
Returns the name of the logger that created this record.

Returns:

 

getMessage

String getMessage()
Returns the raw message of this record.

Returns:

 

getParameters

Array<Object> getParameters()
Returns the message parameters of this record.

Returns:

 

getSerial

int getSerial()
Returns this record's serial number. Every record that is created is assigned a serial number, beginning with 1.

Returns:

 

getStack

Array<Function> getStack()
Returns the complete JavaScript stack from when this record was created. May be null or empty if the record was not specified to store the stack.

Returns:

 

jsx3.util

class MessageFormat

Object
->jsx3.lang.Object
  ->jsx3.util.MessageFormat

class MessageFormat
extends jsx3.lang.Object
Constructs messages from a pattern and parameters. A message format takes a list of arguments, formats them, and inserts them into the pattern at specific places.

Replacement tokens are delimited with curly braces. Tokens begin with an integer, which determines the format parameter that is inserted in place of the token. The following tokens are supported where n is the zero-based parameter index: The formatting of date, time, datetime, and number tokens depends on the locale of the message format. The formats used to format such tokens inherit their locale from the message format. If no locale is passed to the message format constructor, the default system locale is used.

Within a format, single quotes (') delimit quoted sequences that are not parsed for tokens. Therefore, in order to insert a curly bracket in a message format, it should be surrounded by single quotes: new MessageFormat("A curly bracket: '{'"). To insert a single quote character, use two single quotes in succession: new MessageFormat("A single quote: ''").

Since:

3.2

See Also:

jsx3.util.NumberFormat, jsx3.util.DateFormat

Constructor Summary
void
init(strFormat : String, objLocale : jsx3.util.Locale)
The instance initializer.
Method Summary
String
format(args : Object... | Array<Object>)
Formats a collection of objects according to this message format.
jsx3.util.Locale
Returns the locale of this message format.
void
Sets the locale of this message format.
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strFormat : String, objLocale : jsx3.util.Locale)
The instance initializer.

Parameters:

strFormatthe format pattern.
objLocalethe locale of the format. The locale affects how numbers and dates are formatted. If this parameter is omitted, the system locale is used.

Throws:

{jsx3.lang.Exception}if strFormat cannot be parsed.
Method Detail

format

String format(args : Object... | Array<Object>)
Formats a collection of objects according to this message format.

Parameters:

argsthe argument objects. Replacement tokens of the pattern of this format will be replaced by these arguments.

Returns:

the string resulting from the pattern and arguments.  

getLocale

jsx3.util.Locale getLocale()
Returns the locale of this message format.

Returns:

 

setLocale

void setLocale(objLocale : jsx3.util.Locale)
Sets the locale of this message format.

Parameters:

objLocale

toString

String toString()

Returns:

 

Overrides:


jsx3.util

class NumberFormat

Object
->jsx3.lang.Object
  ->jsx3.util.NumberFormat

class NumberFormat
extends jsx3.lang.Object
Formats numbers. This class in localized, meaning that numbers are formatted in a locale-sensitive way.

The format takes the form: Prefix Format Suffix. A single number format can specify a format for a positive value and one for a negative value. In this case the form is: PosPrefix PosFormat PosSuffix;NegPrefix NegFormat NegSuffix. (The spaces between prefix, format, and suffix should not be included in the actual format.)

The format can include the following characters. Each character is replaced with the locale-specific text when a number is formatted.

Since:

3.2

Field Summary
static int
Type for a currency number format.
static int
Type for an integer number format.
static int
Type for a decimal number format.
Constructor Summary
void
init(strFormat : String, objLocale : jsx3.util.Locale)
Creates a new number format instance.
Method Summary
String
format(number : String | Object | Number)
static jsx3.util.NumberFormat
Returns a currency number format appropriate for objLocale.
static jsx3.util.NumberFormat
getInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a number format appropriate for objLocale.
static jsx3.util.NumberFormat
Returns an integer number format appropriate for objLocale.
jsx3.util.Locale
static jsx3.util.NumberFormat
Returns a general number format appropriate for objLocale.
static jsx3.util.NumberFormat
Returns a percent number format appropriate for objLocale.
Number
parse(s : String)
Parses a string according to this number format and returns the resulting value.
void
String
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

CURRENCY

static final int CURRENCY
Type for a currency number format.

INTEGER

static final int INTEGER
Type for an integer number format.

NUMBER

static final int NUMBER
Type for a decimal number format.
Constructor Detail

init

void init(strFormat : String, objLocale : jsx3.util.Locale)
Creates a new number format instance.

Parameters:

strFormatthe number format.
objLocalethe locale for the format. By default the system locale is used.

Throws:

{jsx3.lang.Exception}if strFormat cannot be parsed.
Method Detail

format

String format(number : String | Object | Number)

Parameters:

number

Returns:

 

getCurrencyInstance

static jsx3.util.NumberFormat getCurrencyInstance(objLocale : jsx3.util.Locale)
Returns a currency number format appropriate for objLocale.

Parameters:

objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getInstance

static jsx3.util.NumberFormat getInstance(intType : int, objLocale : jsx3.util.Locale)
Returns a number format appropriate for objLocale.

Parameters:

intTypeNUMBER, INTEGER, or CURRENCY.
objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

Since:

3.7

getIntegerInstance

static jsx3.util.NumberFormat getIntegerInstance(objLocale : jsx3.util.Locale)
Returns an integer number format appropriate for objLocale.

Parameters:

objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getLocale

jsx3.util.Locale getLocale()

Returns:

 

getNumberInstance

static jsx3.util.NumberFormat getNumberInstance(objLocale : jsx3.util.Locale)
Returns a general number format appropriate for objLocale.

Parameters:

objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

getPercentInstance

static jsx3.util.NumberFormat getPercentInstance(objLocale : jsx3.util.Locale)
Returns a percent number format appropriate for objLocale.

Parameters:

objLocalethe locale for which to return a format. If this parameter is not provided, the default system locale is used.

Returns:

 

parse

Number parse(s : String)
Parses a string according to this number format and returns the resulting value. Note: this method ignores any non-significant characters. This method does not handle localized digit characters other than ASCII 0-9.

Parameters:

s

Returns:

 

Since:

3.7

setLocale

void setLocale(objLocale : jsx3.util.Locale)

Parameters:

objLocale

toString

String toString()

Returns:

 

Overrides:


package jsx3.vector

This package and all contained classes are available only when the Charting add-in is enabled.

Class Summary
jsx3.vector.Block
Defines a base class for GUI controls that implement both the cross-platform box profile painting introduced in 3.2 and the cross-platform (VML/SVG) vector painting, also introduced in 3.2.
jsx3.vector.Canvas
Represents a vector canvas in which vector shapes are painted.
jsx3.vector.Fill
Represents a vector fill, the color and gradient that fills a solid vector shape.
jsx3.vector.Group
Represents a grouping of vector shapes.
jsx3.vector.Line
Paints a vector line defined by two end points.
jsx3.vector.LineGroup
A more efficient way of painting many vector lines of the same color and thickness.
jsx3.vector.Oval
Paints a vector oval bounded by the box defined by its left, top, width, and height.
jsx3.vector.Polygon
Paints a vector polygon defined by a set of points.
jsx3.vector.Rectangle
Paints a vector rectangle.
jsx3.vector.RectangleGroup
A more efficient way of painting many vector rectangles of the same fill and stroke.
jsx3.vector.Shape
Represents a vector shape element.
jsx3.vector.Stroke
Represents a vector line style.
jsx3.vector.Tag
The base class for jsx3.vector.Group and jsx3.vector.Shape.
jsx3.vector.TextLine
Renders text along an arbitrary line.
Method Summary
static String
colorAsHtml(color : int | String)
Converts an integer color to a CSS hex string color.
static Number
Converts degrees (0 at North, clockwise) to radians (0 at East, counterclockwise).
static void
paintEventHandler(obj : jsx3.app.Model, strEvtType : String, strMethod : String, objElm : jsx3.vector.Tag)
Renders a cross-platform vector event handler.
static void
updateVector(objNew : jsx3.html.Tag, objExisting : HTMLElement)
Updates a rendered vector HTML element, objExisting, with an in-memory vector tag, objNew.
Method Detail

colorAsHtml

static String colorAsHtml(color : int | String)
Converts an integer color to a CSS hex string color. If the color parameter is not a number, this function returns the argument as a string.

Parameters:

colorThe number to convert to hex.

Returns:

The CSS hex string.  

degreesToRadians

static Number degreesToRadians(degrees : Number)
Converts degrees (0 at North, clockwise) to radians (0 at East, counterclockwise).

Parameters:

degreesa degree value; 0 points North, increasing values go clockwise.

Returns:

a radian value, between 0 and 2*pi; 0 points East, increasing values go counterclockwise.  

paintEventHandler

static void paintEventHandler(obj : jsx3.app.Model, strEvtType : String, strMethod : String, objElm : jsx3.vector.Tag)
Renders a cross-platform vector event handler.

Parameters:

obj
strEvtTypethe event type, one of jsx3.gui.Event.CLICK, etc.
strMethodthe instance method to call on obj when the event is received.
objElmthe HTML element to which to add the event handler.

updateVector

static void updateVector(objNew : jsx3.html.Tag, objExisting : HTMLElement)
Updates a rendered vector HTML element, objExisting, with an in-memory vector tag, objNew. For example,
var objElm = document.getElementById("vectorId");
var objVector = new jsx3.vector.Oval(0, 0, 100, 100);
objVector.setFill(new jsx3.vector.Fill(0xFFFF00));
jsx3.vector.updateVector(objVector, objElm);

Parameters:

objNew
objExisting

jsx3.vector

class Block

Object
->jsx3.lang.Object
  ->jsx3.app.Model
    ->jsx3.gui.Painted
      ->jsx3.gui.Block
        ->jsx3.vector.Block

All Implemented Interfaces:

jsx3.gui.Interactive, jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.chart.Chart

class Block
extends jsx3.gui.Block
Defines a base class for GUI controls that implement both the cross-platform box profile painting introduced in 3.2 and the cross-platform (VML/SVG) vector painting, also introduced in 3.2.

This class should be extended by custom GUI classes that will display vector elements.

Since:

3.5

Method Summary
jsx3.vector.Tag
Instantiates and returns a new instance of jsx3.vector.Canvas.
jsx3.vector.Tag
Creates the vector tag tree that will render this GUI control.
jsx3.vector.Tag
Returns the vector canvas on which this control paints itself.
void
paintEventHandler(strEvtType : String, strMethod : String, objElm : jsx3.vector.Tag)
Renders a cross-platform vector event handler.
boolean
Updates the pre-existing vector tree of this control on, for example, a resize or repaint event.
Methods Inherited From jsx3.gui.Block
getBackground, getBackgroundColor, getBorder, getCDFAttribute, getCDFId, getCSSOverride, getClassName, getColor, getCursor, getDimensions, getDisplay, getFontName, getFontSize, getFontWeight, getHeight, getIndex, getLeft, getMargin, getOverflow, getPadding, getRelativePosition, getTagName, getText, getTextAlign, getTip, getTop, getVisibility, getWidth, getZIndex, hideMask, paint, setBackground, setBackgroundColor, setBorder, setCDFAttribute, setCDFId, setCSSOverride, setClassName, setColor, setCursor, setDimensions, setDisplay, setFontName, setFontSize, setFontWeight, setHeight, setIndex, setLeft, setMargin, setOverflow, setPadding, setRelativePosition, setTagName, setText, setTextAlign, setTip, setTop, setVisibility, setWidth, setZIndex, showMask
Methods Inherited From jsx3.gui.Interactive
doEvent, getCanDrag, getCanDrop, getCanMove, getCanSpy, getEvent, getEvents, getMenu, hasEvent, registerHotKey, removeEvent, removeEvents, setCanDrag, setCanDrop, setCanMove, setCanSpy, setEvent, setMenu, setSpyStyles, showSpy
Methods Inherited From jsx3.gui.Painted
focus, getAbsolutePosition, getAttribute, getAttributes, getDynamicProperty, getRendered, insertHTML, onAfterPaint, onAfterRestoreView, paintChild, paintChildren, recalcBox, removeAttribute, removeAttributes, repaint, setAttribute, setDynamicProperty
Methods Inherited From jsx3.app.Model
adoptChild, doClone, findAncestor, findDescendants, getAncestorOfName, getAncestorOfType, getChild, getChildIndex, getChildren, getDescendantOfName, getDescendantsOfType, getFirstChild, getFirstChildOfType, getHelpId, getId, getLastChild, getLoadType, getMetaValue, getNS, getName, getNextSibling, getParent, getPersistence, getPreviousSibling, getServer, getUriResolver, insertBefore, load, loadAndCache, loadXML, onAfterAssemble, onAfterAttach, onBeforeAssemble, onChangeServer, onChildAdded, onDestroy, onRemoveChild, onSetChild, onSetParent, removeChild, removeChildren, selectDescendants, setChild, setHelpId, setLoadType, setMetaValue, setName, setPersistence, toString, toXML, toXMLDoc
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

createCanvas

jsx3.vector.Tag createCanvas()
Instantiates and returns a new instance of jsx3.vector.Canvas. The implementation of createVector() in this class calls this method to create the base vector tag. This method may be overridden to provide a base tag of another type that Canvas.

Returns:

 

createVector

jsx3.vector.Tag createVector()
Creates the vector tag tree that will render this GUI control. Subclasses of this class should override this method to specify the manner in which they render.

The basic template for a method overriding this method is:
CustomVector.prototype.createVector = function() {
  var objCanvas = this.jsxsuper();
  // modify objCanvas, add children, etc.
  return objCanvas;
};
This method should do the work of creating and updating the vector tree to the state when it is ready to be rendered on screen, but without calling updateVector() directly.

Returns:

 

See Also:


getCanvas

jsx3.vector.Tag getCanvas()
Returns the vector canvas on which this control paints itself. If no canvas has already been created, then createVector() is called to create it.

Returns:

 

paintEventHandler

void paintEventHandler(strEvtType : String, strMethod : String, objElm : jsx3.vector.Tag)
Renders a cross-platform vector event handler. When an event of type strEvtType bubbles up to the HTML element rendered by objElm, the instance method of this object whose name is strMethod will be called with two parameters: the browser event wrapped in an instance of jsx3.gui.Event, and the native HTMLElement that defined the event handler.

Parameters:

strEvtTypethe event type, one of jsx3.gui.Event.CLICK, etc.
strMethodthe instance method to call on this object when the event is received.
objElmthe HTML element to which to add the event handler.

See Also:


updateVector

boolean updateVector(objVector : jsx3.vector.Tag)
Updates the pre-existing vector tree of this control on, for example, a resize or repaint event. Methods overriding this method should return true if the update is successful or false to force the vector tree to be completely recreated with createVector().

The basic template for a method overriding this method is:
CustomVector.prototype.updateVector = function(objVector) {
  this.jsxsuper(objVector);
  // modify objCanvas, modify children, etc.
  return true;
};

Parameters:

objVectorthe root of the vector render tree.

Returns:

true if the tree could be updated inline or false if it must be recreated by calling createVector()

See Also:


jsx3.vector

class Canvas

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Canvas

class Canvas
extends jsx3.html.BlockTag
Represents a vector canvas in which vector shapes are painted.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object

jsx3.vector

class Fill

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.vector.Fill

class Fill
extends jsx3.html.Tag
Represents a vector fill, the color and gradient that fills a solid vector shape.

Constructor Summary
void
init(color : int | String, alpha : float)
The instance initializer.
Method Summary
float
Returns the alpha field, as previously set in the constructor or with setAlpha().
float
Returns the alpha2 field, as set with setAlpha2().
int
Returns the angle field (the angle along which the gradient goes), as set with setAngle().
void
Returns the color field, as previously set in the constructor or with setColor().
void
Returns the color2 field, as set with setColor2().
void
? getColor2Html() {String} gets the color2 field, as a CSS hex string
String
Returns the color field, as a CSS hex string.
String
Returns the colors field, as set with setColors().
String
Returns the type field, as set with setType().
void
setAlpha(alpha : float)
Sets the alpha field, valid values are between 0 (transparent) and 1 (opaque).
void
setAlpha2(alpha2 : float)
Sets the alpha2 field, valid values are between 0 (transparent) and 1 (opaque).
void
setAngle(angle : int)
Sets the angle field, valid values are between 0 and 360.
void
setColor(color : String | Number)
Sets the color field.
void
setColor2(color2 : String | Number)
Sets the color2 field.
void
setColors(colors : String)
Sets the colors field, see the documentation for in the VML documentation.
void
setType(type : String)
Sets the type field, valid values are enumerated in the VML specification, though only 'solid', 'gradient', and 'gradientradial' are truly supported by this class.
static jsx3.vector.Fill
Parses a vector fill from its string representation.
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(color : int | String, alpha : float)
The instance initializer.

Parameters:

colorthe color value, as a hex String or 24-bit integer value, defaults to 0x000000
alphathe opacity value, valid values are between 0 and 1, defaults to 1
Method Detail

getAlpha

float getAlpha()
Returns the alpha field, as previously set in the constructor or with setAlpha().

Returns:

alpha  

getAlpha2

float getAlpha2()
Returns the alpha2 field, as set with setAlpha2().

Returns:

alpha2  

getAngle

int getAngle()
Returns the angle field (the angle along which the gradient goes), as set with setAngle().

Returns:

angle  

getColor

void getColor()
Returns the color field, as previously set in the constructor or with setColor().

getColor2

void getColor2()
Returns the color2 field, as set with setColor2().

getColor2Html

void getColor2Html()
? getColor2Html() {String} gets the color2 field, as a CSS hex string

getColorHtml

String getColorHtml()
Returns the color field, as a CSS hex string.

Returns:

 

getColors

String getColors()
Returns the colors field, as set with setColors().

Returns:

colors  

getType

String getType()
Returns the type field, as set with setType().

Returns:

type  

setAlpha

void setAlpha(alpha : float)
Sets the alpha field, valid values are between 0 (transparent) and 1 (opaque)..

Parameters:

alphathe new value for alpha

setAlpha2

void setAlpha2(alpha2 : float)
Sets the alpha2 field, valid values are between 0 (transparent) and 1 (opaque)..

Parameters:

alpha2the new value for alpha2

setAngle

void setAngle(angle : int)
Sets the angle field, valid values are between 0 and 360. 0 is the vector pointing rightward.

Parameters:

anglethe new value for angle

setColor

void setColor(color : String | Number)
Sets the color field.

Parameters:

colorthe new value for color

setColor2

void setColor2(color2 : String | Number)
Sets the color2 field.

Parameters:

color2the new value for color2

setColors

void setColors(colors : String)
Sets the colors field, see the documentation for <fill> in the VML documentation.

Parameters:

colorsthe new value for colors

setType

void setType(type : String)
Sets the type field, valid values are enumerated in the VML specification, though only 'solid', 'gradient', and 'gradientradial' are truly supported by this class.

Parameters:

typethe new value for type

valueOf

static jsx3.vector.Fill valueOf(v : String | jsx3.vector.Fill)
Parses a vector fill from its string representation. The format is "color alpha".

Parameters:

vthe string representation of a fill.

Returns:

null if v is empty, v if v is already a vector fill, or otherwise a new vector fill created by parsing the string according to the format specified above.  

jsx3.vector

class Group

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Group

class Group
extends jsx3.vector.Tag
Represents a grouping of vector shapes.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object

jsx3.vector

class Line

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.Line

class Line
extends jsx3.vector.Shape
Paints a vector line defined by two end points.

Constructor Summary
void
init(left : int, top : int, x1 : int, y1 : int, x2 : int, y2 : int)
The instance initializer.
Method Summary
int
Returns the x1 field.
int
Returns the x2 field.
int
Returns the y1 field.
int
Returns the y2 field.
void
setPoints(x1 : int, y1 : int, x2 : int, y2 : int)
Sets all the coordinates at once.
void
setX1(x1 : int)
Sets the x1 field.
void
setX2(x2 : int)
Sets the x2 field.
void
setY1(y1 : int)
Sets the y1 field.
void
setY2(y2 : int)
Sets the y2 field.
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, x1 : int, y1 : int, x2 : int, y2 : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
x1the x coordinate of the starting point
y1the y coordinate of the starting point
x2the x coordinate of the ending point
y2the y coordinate of the ending point
Method Detail

getX1

int getX1()
Returns the x1 field.

Returns:

x1  

getX2

int getX2()
Returns the x2 field.

Returns:

x2  

getY1

int getY1()
Returns the y1 field.

Returns:

y1  

getY2

int getY2()
Returns the y2 field.

Returns:

y2  

setPoints

void setPoints(x1 : int, y1 : int, x2 : int, y2 : int)
Sets all the coordinates at once.

Parameters:

x1the x coordinate of the starting point
y1the y coordinate of the starting point
x2the x coordinate of the ending point
y2the y coordinate of the ending point

setX1

void setX1(x1 : int)
Sets the x1 field.

Parameters:

x1the new value for x1

setX2

void setX2(x2 : int)
Sets the x2 field.

Parameters:

x2the new value for x2

setY1

void setY1(y1 : int)
Sets the y1 field.

Parameters:

y1the new value for y1

setY2

void setY2(y2 : int)
Sets the y2 field.

Parameters:

y2the new value for y2

jsx3.vector

class LineGroup

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.LineGroup

class LineGroup
extends jsx3.vector.Shape
A more efficient way of painting many vector lines of the same color and thickness.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
void
addLine(x1 : int, y1 : int, x2 : int, y2 : int)
add a line to the group
void
addRelativeLine(x1 : int, y1 : int, dx : int, dy : int)
add a line to the group
void
clear all lines out of the group
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

addLine

void addLine(x1 : int, y1 : int, x2 : int, y2 : int)
add a line to the group

Parameters:

x1the x-coordinate of the start point of the line
y1the y-coordinate of the start point of the line
x2the x-coordinate of the end point of the line
y2the y-coordinate of the end point of the line

addRelativeLine

void addRelativeLine(x1 : int, y1 : int, dx : int, dy : int)
add a line to the group

Parameters:

x1the x-coordinate of the start point of the line
y1the y-coordinate of the start point of the line
dxthe horizontal change from the start to the end point of the line
dythe vertical change from the start to the end point of the line

clearLines

void clearLines()
clear all lines out of the group

jsx3.vector

class Oval

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.Oval

class Oval
extends jsx3.vector.Shape
Paints a vector oval bounded by the box defined by its left, top, width, and height.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object

jsx3.vector

class Polygon

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.Polygon

class Polygon
extends jsx3.vector.Shape
Paints a vector polygon defined by a set of points.

Constructor Summary
void
init(left : int, top : int, points : String | Array)
The instance initializer.
Method Summary
void
setPoints(points : Array)
Sets the polygon points as an array of point objects or strings.
void
Sets the polygon points as an array of coordinates.
void
Sets the points as a string.
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, points : String | Array)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
pointsthe list of points comprising the polygon
Method Detail

setPoints

void setPoints(points : Array)
Sets the polygon points as an array of point objects or strings.

Parameters:

pointsan array of strings or objects to stringify as "x y"

setPointsAsNumberArray

void setPointsAsNumberArray(points : Array)
Sets the polygon points as an array of coordinates.

Parameters:

pointsan array of alternating x and y coordinates

setPointsAsString

void setPointsAsString(points : String)
Sets the points as a string.

Parameters:

pointsa string in the form "x1 y1 x2 y2 ..."

jsx3.vector

class Rectangle

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.Rectangle

class Rectangle
extends jsx3.vector.Shape
Paints a vector rectangle.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
void
clipTo(l1 : int, t1 : int, w1 : int, h1 : int)
Clips this rectangle to the bounds of {l1, t1, w1, h1}.
void
Clips this rectangle to the bounds of obj.
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

clipTo

void clipTo(l1 : int, t1 : int, w1 : int, h1 : int)
Clips this rectangle to the bounds of {l1, t1, w1, h1}.

Parameters:

l1
t1
w1
h1

clipToBox

void clipToBox(obj : jsx3.gui.Block | jsx3.html.BlockTag)
Clips this rectangle to the bounds of obj.

Parameters:

objany object that has getLeft(), etc methods.

jsx3.vector

class RectangleGroup

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.RectangleGroup

class RectangleGroup
extends jsx3.vector.Shape
A more efficient way of painting many vector rectangles of the same fill and stroke.

Constructor Summary
void
init(left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
void
addRectangle(x1 : int, y1 : int, x2 : int, y2 : int)
add a rectangle to this group
void
addRelativeRectangle(x1 : int, y1 : int, w : int, h : int)
add a rectangle to this group
void
clear all rectangles out of the group
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

addRectangle

void addRectangle(x1 : int, y1 : int, x2 : int, y2 : int)
add a rectangle to this group

Parameters:

x1the x-coordinate of the left edge of the rectangle
y1the y-coordinate of the top edge of the rectangle
x2the x-coordinate of the right edge of the rectangle
y2the y-coordinate of the bottom edge of the rectangle

addRelativeRectangle

void addRelativeRectangle(x1 : int, y1 : int, w : int, h : int)
add a rectangle to this group

Parameters:

x1the x-coordinate of the left edge of the rectangle
y1the y-coordinate of the top edge of the rectangle
wthe width of the rectangle
hthe height of the rectangle

clearRectangles

void clearRectangles()
clear all rectangles out of the group

jsx3.vector

class Shape

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape

Direct Known Subclasses:

jsx3.vector.Line, jsx3.vector.LineGroup, jsx3.vector.Oval, jsx3.vector.Polygon, jsx3.vector.Rectangle, jsx3.vector.RectangleGroup, jsx3.vector.TextLine

class Shape
extends jsx3.vector.Tag
Represents a vector shape element.

The vector shape is the principal vector tag. The path field can contain an EPS-like path the defines a complex vector shape.

Constructor Summary
void
init(strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
void
Returns the fill of this shape.
String
Returns the path field.
void
Returns the stroke of this shape.
jsx3.vector.Shape
pathArcTo(cx : int, cy : int, rx : int, ry : int, x1 : int, y1 : int, x2 : int, y2 : int, bCW : boolean)
jsx3.vector.Shape
jsx3.vector.Shape
pathLineTo(x : int, y : int, bRel : boolean)
jsx3.vector.Shape
pathMoveTo(x : int, y : int, bRel : boolean)
void
Sets the fill of this shape, other fills may be present as children of this instance.
void
setPath(path : String)
Sets the path field.
void
Sets the stroke of this shape, other strokes may be present as children of this instance.
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

strTagName
leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

getFill

void getFill()
Returns the fill of this shape.

getPath

String getPath()
Returns the path field.

Returns:

path  

getStroke

void getStroke()
Returns the stroke of this shape.

pathArcTo

jsx3.vector.Shape pathArcTo(cx : int, cy : int, rx : int, ry : int, x1 : int, y1 : int, x2 : int, y2 : int, bCW : boolean)

Parameters:

cx
cy
rx
ry
x1
y1
x2
y2
bCW

Returns:

this object.  

pathClose

jsx3.vector.Shape pathClose()

Returns:

this object.  

pathLineTo

jsx3.vector.Shape pathLineTo(x : int, y : int, bRel : boolean)

Parameters:

x
y
bRel

Returns:

this object.  

pathMoveTo

jsx3.vector.Shape pathMoveTo(x : int, y : int, bRel : boolean)

Parameters:

x
y
bRel

Returns:

this object.  

setFill

void setFill(fill : jsx3.vector.Fill)
Sets the fill of this shape, other fills may be present as children of this instance.

Parameters:

fillthe fill value.

setPath

void setPath(path : String)
Sets the path field.

Parameters:

paththe new value for path

setStroke

void setStroke(stroke : jsx3.vector.Stroke)
Sets the stroke of this shape, other strokes may be present as children of this instance.

Parameters:

strokethe stroke value.

jsx3.vector

class Stroke

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.vector.Stroke

class Stroke
extends jsx3.html.Tag
Represents a vector line style.

Constructor Summary
void
init(color : int | String, width : int, alpha : float)
The instance initializer.
Method Summary
float
Returns the alpha field.
int | String
Returns the color field.
String
Returns the color field, as a CSS hex string.
int
Returns the width field.
void
setAlpha(alpha : float)
Sets the alpha field.
void
setColor(color : int | String)
Sets the color field.
void
setWidth(width : int)
Sets the width field.
static VectorStroke
parses a VectorStroke from a string representation, that format is "color width alpha"
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(color : int | String, width : int, alpha : float)
The instance initializer.

Parameters:

colorthe color value, as a hex String or 24-bit integer value, defaults to 0x000000
widththe width of the stroke, in pixels, defaults to 1
alphathe opacity value, valid values are between 0 and 1, defaults to 1
Method Detail

getAlpha

float getAlpha()
Returns the alpha field.

Returns:

alpha  

getColor

int | String getColor()
Returns the color field.

Returns:

color  

getColorHtml

String getColorHtml()
Returns the color field, as a CSS hex string.

Returns:

 

getWidth

int getWidth()
Returns the width field.

Returns:

width  

setAlpha

void setAlpha(alpha : float)
Sets the alpha field.

Parameters:

alphathe new value for alpha

setColor

void setColor(color : int | String)
Sets the color field.

Parameters:

colorthe new value for color

setWidth

void setWidth(width : int)
Sets the width field.

Parameters:

widththe new value for width

valueOf

static VectorStroke valueOf(v : String)
parses a VectorStroke from a string representation, that format is "color width alpha"

Parameters:

vthe string representation

Returns:

null if v is empty, v if v is already a VectorStroke, or otherwise a new VectorStroke created by parsing the string according to the format specified above  

jsx3.vector

class Tag

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag

Direct Known Subclasses:

jsx3.vector.Group, jsx3.vector.Shape

class Tag
extends jsx3.html.BlockTag
The base class for jsx3.vector.Group and jsx3.vector.Shape. Defines getters and setters for the shared vector tag attributes and CSS style extensions.

Constructor Summary
void
init(strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.
Method Summary
int
Returns the rotation field.
void
Returns the tooltip, the text that is displayed on mouse over.
void
setRotation(rotation : int)
Sets the rotation field, an angle between 0 and 360.
void
setToolTip(title : String)
Sets the tooltip, the text that is displayed on mouse over.
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(strTagName : String, left : int, top : int, width : int, height : int)
The instance initializer.

Parameters:

strTagName
leftleft position (in pixels) of the object relative to its parent container
toptop position (in pixels) of the object relative to its parent container
widthwidth (in pixels) of the object
heightheight (in pixels) of the object
Method Detail

getRotation

int getRotation()
Returns the rotation field.

Returns:

rotation  

getToolTip

void getToolTip()
Returns the tooltip, the text that is displayed on mouse over.

setRotation

void setRotation(rotation : int)
Sets the rotation field, an angle between 0 and 360.

Parameters:

rotationthe new value for rotation

setToolTip

void setToolTip(title : String)
Sets the tooltip, the text that is displayed on mouse over.

Parameters:

title

jsx3.vector

class TextLine

Object
->jsx3.lang.Object
  ->jsx3.html.Tag
    ->jsx3.html.BlockTag
      ->jsx3.vector.Tag
        ->jsx3.vector.Shape
          ->jsx3.vector.TextLine

All Implemented Interfaces:

jsx3.html.FontTag

class TextLine
extends jsx3.vector.Shape
Renders text along an arbitrary line.

Constructor Summary
void
init(x1 : int, y1 : int, x2 : int, y2 : int, text : String)
The instance initializer.
Method Summary
String
Returns the text field.
void
setText(text : String)
Sets the text field, the text to display on the text path.
Methods Inherited From jsx3.html.FontTag
getColor, getFontFamily, getFontSize, getFontStyle, getFontWeight, getTextAlign, getTextDecoration, setColor, setFontFamily, setFontSize, setFontStyle, setFontWeight, setTextAlign, setTextDecoration
Methods Inherited From jsx3.vector.Shape
getFill, getPath, getStroke, pathArcTo, pathClose, pathLineTo, pathMoveTo, setFill, setPath, setStroke
Methods Inherited From jsx3.vector.Tag
getRotation, getToolTip, setRotation, setToolTip
Methods Inherited From jsx3.html.BlockTag
getBackgroundColor, getDimensions, getHeight, getLeft, getMargin, getMarginDimensions, getPadding, getPaddingDimensions, getPosition, getTop, getWidth, getZIndex, setBackgroundColor, setDimensions, setHeight, setLeft, setMargin, setPadding, setPosition, setTop, setWidth, setZIndex
Methods Inherited From jsx3.html.Tag
appendChild, getChildren, getClassName, getFirstChildOfType, getId, getParent, getProperty, getStyle, getTagNS, getTagName, onAppendChild, onRemoveChild, paint, paintDom, paintUpdate, release, removeChild, removeChildren, removeProperty, removeStyle, replaceChild, setClassName, setExtraStyles, setId, setProperty, setStyle, toString
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Constructor Detail

init

void init(x1 : int, y1 : int, x2 : int, y2 : int, text : String)
The instance initializer.

Parameters:

x1
y1
x2
y2
textthe text to display on the text path
Method Detail

getText

String getText()
Returns the text field.

Returns:

text  

setText

void setText(text : String)
Sets the text field, the text to display on the text path.

Parameters:

textthe new value for text

package jsx3.xml

XML related classes.

Class Summary
jsx3.xml.CDF
Mixin interface that provides methods for accessing and manipulating an XML document in CDF schema.
jsx3.xml.CDF.Document
A subclass of jsx3.xml.Document that implements the CDF interface.
jsx3.xml.Cacheable
A mixin interface that provides the following capabilities to implementing classes:
jsx3.xml.Document
Wrapper of the native browser XML document class.
jsx3.xml.DojoDataStore
Provides access to Dojo data store through the CDF interface.
jsx3.xml.Entity
Wrapper of the native browser XML node class.
jsx3.xml.Processor
Deprecated. Use jsx3.xml.Template instead.
jsx3.xml.Template
Wrapper of the native browser XSLT processor.
jsx3.xml.XslDocument
An extension of jsx3.xml.Document that encapsulates a compiled XSL template.

jsx3.xml

interface CDF

jsx3.xml.CDF

All Known Implementing Classes:

jsx3.chart.AreaChart, jsx3.chart.BCChart, jsx3.chart.BarChart, jsx3.chart.CartesianChart, jsx3.chart.Chart, jsx3.chart.ColumnChart, jsx3.chart.LineChart, jsx3.chart.PieChart, jsx3.chart.PlotChart, jsx3.chart.RadialChart, jsx3.gui.CDF, jsx3.gui.Grid, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Menu, jsx3.gui.Select, jsx3.gui.Table, jsx3.gui.Tree, jsx3.xml.CDF.Document, jsx3.xml.DojoDataStore

abstract interface CDF
Mixin interface that provides methods for accessing and manipulating an XML document in CDF schema.

Classes that implement this interface must also define a getXML() method. This interface uses that method to access the XML document for which it provides a CDF interface.

Class Summary
jsx3.xml.CDF.Document
A subclass of jsx3.xml.Document that implements the CDF interface.
Field Summary
static String
static String
static String
static String
static String
static String
static String
static String
static String
static int
static String
static String
static int
static int
static int
Method Summary
jsx3.xml.Entity
adoptRecord(strSourceId : String | jsx3.xml.CDF, strRecordId : String, strParentRecordId : String, bRedraw : boolean)
Transfers a CDF record from another object to this object.
jsx3.xml.Entity
adoptRecordBefore(strSourceId : String | jsx3.xml.CDF, strRecordId : String, strSiblingRecordId : String, bRedraw : boolean)
Equivalent to adoptRecord, except that the to-be relationship is as a previousSibling to the CDF record identified by the parameter, strSiblingRecordId This method fails quietly if any of the following conditions apply: there is no record with a jsxid equal to strSourceId there is no record in the source object with a jsxid equal to strRecordId strSiblingRecordId is specified and there is no record in this object with a jsxid equal to strParentRecordId this object already has a record with jsxid equal to the record to adopt
void
convertProperties(objProps : jsx3.app.Properties, arrProps : Array<String>, bUnion : boolean)
Converts all attributes in this CDF document that are property keys of the form {key} to the value of the property.
jsx3.xml.Entity
deleteRecord(strRecordId : String, bRedraw : boolean)
Removes a record from the XML data source of this object.
void
deleteRecordProperty(strRecordId : String, strPropName : String, bRedraw : boolean)
Removes a specific property from a record.
static String
Generates a unique jsxid attribute for a CDF record.
Object<String, String>
getRecord(strRecordId : String)
Returns an object containing the attributes of a particular CDF record as property/value pairs.
void
Returns an array of jsxid from this CDF .
jsx3.xml.Entity
getRecordNode(strRecordId : String)
Returns a record from the XML data source of this object.
static String
Deprecated.
jsx3.xml.Entity
insertRecord(objRecord : Object<String, String>, strParentRecordId : String, bRedraw : boolean)
Inserts a new record into the XML data source of this object.
jsx3.xml.Entity
insertRecordBefore(objRecord : Object<String, String>, strSiblingRecordId : String, bRedraw : boolean)
Creates a new CDF record and inserts it into the CDF data source of this object, before the record identified by strSiblingRecordId.
void
insertRecordNode(objRecordNode : jsx3.xml.Entity, strParentRecordId : String, bRedraw : boolean)
Inserts a new record into the XML data source of this object.
jsx3.xml.CDF
insertRecordProperty(strRecordId : String, strPropName : String, strPropValue : String, bRedraw : boolean)
Inserts a new property into an existing record with jsxid equal to strRecordId.
static jsx3.xml.Document
Creates a new XML document that represents an empty CDF document.
abstract void
redrawRecord(strRecordId : String, intAction : int)
An abstract method that must be implemented by any class that implements this interface.
jsx3.xml.Document
Deprecated. use jsx3.xml.Cacheable.resetXmlCacheData() instead
void
resetData(bRepaint : boolean)
Deprecated. Use jsx3.xml.Cacheable.clearXmlData() instead.
Field Detail

ATTR_DISABLED

static final String ATTR_DISABLED

ATTR_EXECUTE

static final String ATTR_EXECUTE

ATTR_ID

static final String ATTR_ID

ATTR_IMG

static final String ATTR_IMG

ATTR_KEYCODE

static final String ATTR_KEYCODE

ATTR_SELECTED

static final String ATTR_SELECTED

ATTR_TEXT

static final String ATTR_TEXT

ATTR_TIP

static final String ATTR_TIP

ATTR_UNSELECTABLE

static final String ATTR_UNSELECTABLE

DELETE

static final int DELETE

ELEM_RECORD

static final String ELEM_RECORD

ELEM_ROOT

static final String ELEM_ROOT

INSERT

static final int INSERT

INSERTBEFORE

static final int INSERTBEFORE

UPDATE

static final int UPDATE
Method Detail

adoptRecord

jsx3.xml.Entity adoptRecord(strSourceId : String | jsx3.xml.CDF, strRecordId : String, strParentRecordId : String, bRedraw : boolean)
Transfers a CDF record from another object to this object. If no XML data source exists yet for this object, an empty one is created before adding the new record. This method always updates the on-screen view of both the source and destination objects.

This method fails quietly if any of the following conditions apply:
  • there is no object with id equal to strSourceId
  • there is no record in the source object with jsxid equal to strRecordId
  • strParentRecordId is specified and there is no record in this object with jsxid equal to strParentRecordId
  • the this object already has a record with jsxid equal to the record to adopt

Parameters:

strSourceIdeither the id of the source object or the source object itself.
strRecordIdthe jsxid attribute of the data record in the source object to transfer.
strParentRecordIdthe unique jsxid of an existing record. If this optional parameter is provided, the adopted record will be added as a child of this record. Otherwise, the adopted record will be added to the root data element.
bRedrawforces suppression of the insert event

Returns:

the adopted record.  

adoptRecordBefore

jsx3.xml.Entity adoptRecordBefore(strSourceId : String | jsx3.xml.CDF, strRecordId : String, strSiblingRecordId : String, bRedraw : boolean)
Equivalent to adoptRecord, except that the to-be relationship is as a previousSibling to the CDF record identified by the parameter, strSiblingRecordId

This method fails quietly if any of the following conditions apply:
  • there is no record with a jsxid equal to strSourceId
  • there is no record in the source object with a jsxid equal to strRecordId
  • strSiblingRecordId is specified and there is no record in this object with a jsxid equal to strParentRecordId
  • this object already has a record with jsxid equal to the record to adopt

Parameters:

strSourceIdeither the id of the source object or the source object itself.
strRecordIdthe jsxid attribute of the data record in the source object to transfer.
strSiblingRecordIdthe unique jsxid of an existing record in front of which the record identified by strSourceId will be placed
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the deleted record.

Returns:

the adopted record.  

convertProperties

void convertProperties(objProps : jsx3.app.Properties, arrProps : Array<String>, bUnion : boolean)
Converts all attributes in this CDF document that are property keys of the form {key} to the value of the property.

Parameters:

objPropsthe properties repository to query.
arrPropsif provided, these attributes are converted rather than the default set of attributes.
bUnionif true, arrProps is combined with the default set of attributes and those attributes are converted.

deleteRecord

jsx3.xml.Entity deleteRecord(strRecordId : String, bRedraw : boolean)
Removes a record from the XML data source of this object.

Parameters:

strRecordIdthe jsxid attribute of the data record to remove.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the deleted record.

Returns:

the record removed from the data source or null if no such record found.  

deleteRecordProperty

void deleteRecordProperty(strRecordId : String, strPropName : String, bRedraw : boolean)
Removes a specific property from a record. If no such record exists in the XML document, this method fails quietly.

Parameters:

strRecordIdthe jsxid attribute of the data record to modify.
strPropNamethe name of the property to remove from the record.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the deleted property.

getKey

static String getKey()
Generates a unique jsxid attribute for a CDF record. This method can be used for new CDF records when there is no natural unique key to assign to them.

Returns:

 

getRecord

Object<String, String> getRecord(strRecordId : String)
Returns an object containing the attributes of a particular CDF record as property/value pairs. The object returned by this method is a copy of the underlying data. Therefore, updates to this object will not affect the underlying data.

The following two lines of code evaluate to the same value:
objCDF.getRecord(strId).propName;
objCDF.getRecordNode(strId).getAttribute("propName");

Parameters:

strRecordIdthe jsxid attribute of the data record to return.

Returns:

the object representation of a CDF node or null if no such record found. 

See Also:


getRecordIds

void getRecordIds()
Returns an array of jsxid from this CDF .

Returns:

{Array[String]} the array of jsxid.  

getRecordNode

jsx3.xml.Entity getRecordNode(strRecordId : String)
Returns a record from the XML data source of this object. This returned value is a handle to the record and not a clone. Therefore, any updates made to the returned value with update the XML document of this object. To reflect such changes in the on-screen view of this object, call redrawRecord(strRecordId, jsx3.xml.CDF.UPDATE); on this object.

Parameters:

strRecordIdthe jsxid attribute of the data record to return.

Returns:

the record node or null if none exists with a jsxid attribute equal to strRecordId

See Also:

,

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00").

Returns:

 

insertRecord

jsx3.xml.Entity insertRecord(objRecord : Object<String, String>, strParentRecordId : String, bRedraw : boolean)
Inserts a new record into the XML data source of this object. If no XML data source exists yet for this object, an empty one is created before adding the new record. If a record already exists with an id equal to the jsxid property of objRecord, the operation is treated as an update, meaning the existing record is completely removed and a new record with the given jsxid is inserted.

Parameters:

objRecorda JavaScript object containing property/value pairs that define the attributes of the XML entity to create. Note that most classes that implement this interface require that all records have an attribute named jsxid that is unique across all records in the XML document. All property values will be treated as strings. Additionally, the following 3 characters are escaped: " > <.
strParentRecordIdthe unique jsxid of an existing record. If this optional parameter is provided and a record exists with a matching jsxid attribute, the new record will be added as a child of this record. Otherwise, the new record will be added to the root data element. However, if a record already exists with a jsxid attribute equal to the jsxid property of objRecord, this parameter will be ignored. In this case adoptRecord() must be called to change the parent of the record.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the additional record.

Returns:

the newly created or updated entity. 

See Also:


insertRecordBefore

jsx3.xml.Entity insertRecordBefore(objRecord : Object<String, String>, strSiblingRecordId : String, bRedraw : boolean)
Creates a new CDF record and inserts it into the CDF data source of this object, before the record identified by strSiblingRecordId.

This method fails quietly if any of the following conditions apply:
  • there is no existing record with a jsxid equal to strSiblingRecordId
  • there is an existing record with jsxid equal to objRecord.jsxid

Parameters:

objRecorda JavaScript object containing property/value pairs that define the attributes of the XML entity to create. Note that most classes that implement this interface require that all records have an attribute named jsxid that is unique across all records in the XML document. All property values will be treated as strings. Additionally, the following 3 characters are escaped: " > <.
strSiblingRecordIdthe unique jsxid of an existing record before which the new record will be inserted.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the additional record.

Returns:

the newly created entity. 

See Also:


insertRecordNode

void insertRecordNode(objRecordNode : jsx3.xml.Entity, strParentRecordId : String, bRedraw : boolean)
Inserts a new record into the XML data source of this object. This method is the same as insertRecord() except that its first parameter is of type jsx3.xml.Entity rather than Object.

Parameters:

objRecordNodean XML element of name record. Note that most classes that implement this interface require that all records have an attribute named jsxid that is unique across all records in the XML document.
strParentRecordIdthe unique jsxid of an existing record. If this optional parameter is provided and a record exists with a matching jsxid attribute, the new record will be added as a child of this record. Otherwise, the new record will be added to the root data element.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the additional record.

See Also:


insertRecordProperty

jsx3.xml.CDF insertRecordProperty(strRecordId : String, strPropName : String, strPropValue : String, bRedraw : boolean)
Inserts a new property into an existing record with jsxid equal to strRecordId. If the property already exists, the existing property value will be updated. If no such record exists in the XML document, this method fails quietly.

Parameters:

strRecordIdthe jsxid attribute of the data record to modify.
strPropNamethe name of the property to insert into the record.
strPropValuethe value of the property to insert.
bRedrawif true or null, the on-screen view of this object is immediately updated to reflect the inserted property.

Returns:

this object.  

newDocument

static jsx3.xml.Document newDocument()
Creates a new XML document that represents an empty CDF document. The XML source of the new document is <data jsxid="jsxroot"/>.

Returns:

the newly created document.  

redrawRecord

abstract void redrawRecord(strRecordId : String, intAction : int)
An abstract method that must be implemented by any class that implements this interface. Implementations of this method should redraw the specified record in the on-screen view.

Parameters:

strRecordIdthe jsxid attribute of the data record to redraw.
intActionINSERT, UPDATE, or DELETE.

See Also:

, ,

reloadFromSource

jsx3.xml.Document reloadFromSource(bSystem : boolean)
Deprecated. use jsx3.xml.Cacheable.resetXmlCacheData() instead
Removes this object's existing document from the cache and reloads the document from its original source. This method is different from the method resetData() in that this method does not reset the XML document of this object to an empty CDF document.

Parameters:

bSystemif true, the document will be removed even if this is a system-owned document

Returns:

jsx3.xml.Document instance 

See Also:

,

resetData

void resetData(bRepaint : boolean)
Deprecated. Use jsx3.xml.Cacheable.clearXmlData() instead.
Resets the XML of this control to the value returned by CDF.newDocument() and places the document in the server cache.

Parameters:

bRepaintif true or null, the on-screen view of this object is immediately updated to reflect the inserted property.

See Also:

,

jsx3.xml

class CDF.Document

Object
->jsx3.lang.Object
  ->jsx3.xml.Entity
    ->jsx3.xml.Document
      ->jsx3.xml.CDF.Document

All Implemented Interfaces:

jsx3.util.EventDispatcher, jsx3.xml.CDF

class CDF.Document
extends jsx3.xml.Document
A subclass of jsx3.xml.Document that implements the CDF interface. This class simply exposes the CDF convenience methods on an XML document.

Method Summary
jsx3.xml.Document
Returns this document to conform to the contract of the jsx3.xml.CDF interface.
static jsx3.xml.CDF.Document
Creates a new XML document that represents an empty CDF document.
void
redrawRecord(strRecordId : String, intAction : int)
No-op.
static jsx3.xml.CDF.Document
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, reloadFromSource, resetData
Methods Inherited From jsx3.xml.Document
cloneDocument, createDocumentElement, createNamespaceAxis, createProcessingInstruction, getAsync, getDeclaredNamespaces, getNativeDocument, getResolveExternals, getSelectionLanguage, getSelectionNamespaces, getSourceURL, getValidateOnParse, getXmlEncoding, getXmlStandalone, getXmlVersion, load, loadXML, serialize, setAsync, setResolveExternals, setSelectionLanguage, setSelectionNamespaces, setValidateOnParse
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.xml.Entity
appendChild, cloneNode, createNode, equals, getAttribute, getAttributeNames, getAttributeNode, getAttributes, getBaseName, getChildIterator, getChildNodes, getError, getFirstChild, getLastChild, getNamespaceURI, getNative, getNextSibling, getNodeName, getNodeType, getOwnerDocument, getParent, getPrefix, getPreviousSibling, getRootNode, getValue, hasError, insertBefore, removeAttribute, removeAttributeNode, removeChild, removeChildren, replaceNode, selectNodeIterator, selectNodes, selectSingleNode, setAttribute, setAttributeNode, setValue, toString, transformNode
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

getXML

jsx3.xml.Document getXML()
Returns this document to conform to the contract of the jsx3.xml.CDF interface.

Returns:

this object.  

Overrides:


newDocument

static jsx3.xml.CDF.Document newDocument()
Creates a new XML document that represents an empty CDF document. The XML source of the new document is <data jsxid="jsxroot"/>.

Returns:

the newly created document.  

redrawRecord

void redrawRecord(strRecordId : String, intAction : int)
No-op.

Parameters:

strRecordIdthe jsxid attribute of the data record to redraw.
intActionINSERT, UPDATE, or DELETE.

Overrides:


wrap

static jsx3.xml.CDF.Document wrap(objXML : jsx3.xml.Document)

Parameters:

objXML

Returns:

 

jsx3.xml

interface Cacheable

jsx3.xml.Cacheable

All Known Implementing Classes:

jsx3.chart.AreaChart, jsx3.chart.BCChart, jsx3.chart.BarChart, jsx3.chart.CartesianChart, jsx3.chart.Chart, jsx3.chart.ColumnChart, jsx3.chart.LineChart, jsx3.chart.PieChart, jsx3.chart.PlotChart, jsx3.chart.RadialChart, jsx3.gui.BlockX, jsx3.gui.CDF, jsx3.gui.Grid, jsx3.gui.List, jsx3.gui.Matrix, jsx3.gui.Menu, jsx3.gui.Select, jsx3.gui.Table, jsx3.gui.Tree

interface Cacheable
A mixin interface that provides the following capabilities to implementing classes: A class that implement this interface should usually be a subclass of jsx3.app.Model since this interface assumes that its instances have methods in that class (in particular getId() and getServer()).

As of version 3.2 using custom XSL templates for built-in GUI classes implementing this interface is deprecated. Therefore, several methods related to storing per-instance XSL documents are deprecated.

Since:

3.1

Field Summary
static int
Value of the shareResources property for an object that removes its XML and XSL documents from the server XML cache when it is destroyed.
static String
JSX/xsl/xml.xsl
static String
Deprecated.
static int
Value of the shareResources property for an object that leaves its XML and XSL documents in the server XML cache when it is destroyed.
Method Summary
void
Resets the XML source document stored in the server cache under the XML ID of this object to an empty CDF document.
jsx3.xml.Entity
Deprecated.
int
Returns whether this object removes its XML and XSL source documents from the cache of its server when it is destroyed.
static String
Deprecated.
jsx3.xml.Document
Returns the XML source document of this object.
String
Returns the XML ID of this object.
String
Returns the XML string of this object.
Array<String>
Returns the list of XML transformers of this object.
String
Returns the XML URL of this object.
jsx3.xml.Document
Returns the XSL source document of this object.
String
Returns the XSL ID of this object.
Object<String, String>
Returns a map containing all the parameters to pass to the XSL stylesheet during transformation.
String
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
String
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
int
Returns whether the XML data source of this object is loaded asynchronously.
int
Returns whether this object is bound to the XML document stored in the data cache.
protected void
onXmlBinding(objEvent : Object)
This method is called in two situations: When the datasource of this object finishes loading (success, error, or timeout), if the xmlAsync property of this object is true, its datasource is specified as an XML URL, and the first time doTransform() was called the datasource was still loading.
jsx3.xml.Cacheable
removeXSLParam(strName : String)
Removes a parameter from the list of parameters to pass to the XSL stylesheet during transformation.
jsx3.xml.Cacheable
Removes all parameters from the list of parameters to pass to the XSL stylesheet during transformation.
void
Removes the XML and XSL source documents from the server cache.
void
Deprecated. renamed to clearXmlData()
void
Removes the XML source document stored under the XML ID of this object from the server cache.
void
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
void
setNodeSet(objNodeSet : jsx3.xml.Entity)
Deprecated.
jsx3.xml.Cacheable
setShareResources(intShare : int)
Sets whether this object removes its XML and XSL source documents from the cache of its server when it is destroyed.
jsx3.xml.Document
Sets the source document of this object as though objDoc were retrieved from the XML URL or XML string of this object.
jsx3.xml.Cacheable
setXMLId(strXMLId : String)
Sets the XML ID of this object.
jsx3.xml.Cacheable
setXMLString(strXML : String)
Sets the XML string of this object.
void
Sets the list of XML transformers of this object.
jsx3.xml.Cacheable
setXMLURL(strXMLURL : String)
Sets the XML URL of this object.
jsx3.xml.Cacheable
setXSLId(strXSLId : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
jsx3.xml.Cacheable
setXSLParam(strName : String, strValue : String)
Adds a name/value pair to the list of parameters to pass to the XSL stylesheet during transformation.
jsx3.xml.Cacheable
setXSLString(strXSL : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
jsx3.xml.Cacheable
setXSLURL(strXSLURL : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
jsx3.xml.Cacheable
setXmlAsync(bAsync : boolean)
Sets whether the XML data source of this object is loaded asynchronously.
jsx3.xml.Cacheable
setXmlBind(bBind : ?)
Sets whether this object is bound to the XML document stored in the data cache.
Field Detail

CLEANUPRESOURCES

static final int CLEANUPRESOURCES
Value of the shareResources property for an object that removes its XML and XSL documents from the server XML cache when it is destroyed.

DEFAULTSTYLESHEET

static String DEFAULTSTYLESHEET
JSX/xsl/xml.xsl

DEFAULTXSLCACHEID

static String DEFAULTXSLCACHEID
Deprecated.
JSX_XML_XSL

SHARERESOURCES

static final int SHARERESOURCES
Value of the shareResources property for an object that leaves its XML and XSL documents in the server XML cache when it is destroyed.
Method Detail

clearXmlData

void clearXmlData()
Resets the XML source document stored in the server cache under the XML ID of this object to an empty CDF document.

See Also:


getNodeSet

jsx3.xml.Entity getNodeSet()
Deprecated.
Returns the node set of this object.

Returns:

 

getShareResources

int getShareResources()
Returns whether this object removes its XML and XSL source documents from the cache of its server when it is destroyed.

Returns:

CLEANUPRESOURCES or SHARERESOURCES.  

getVersion

static String getVersion()
Deprecated.
gets the release/build for the class (i.e., "2.2.00")

Returns:

 

getXML

jsx3.xml.Document getXML()
Returns the XML source document of this object. The XML document is determined by the following steps:
  1. If an XML document exists in the server cache under an ID equal to the XML ID of this object, that document is returned.
  2. If the XML string of this object is not empty, a new document is created by parsing this string.
  3. If the XML URL of this object is not empty, a new document is created by parsing the file at the location specified by the URL resolved against the server owning this object.
  4. Otherwise, an empty CDF document is returned.
If a new document is created for this object (any of the steps listed above except for the first one), the following actions are also taken:
  1. If creating the document resulted in an error (XML parsing error, file not found error, etc) the offending document is returned immediately.
  2. Otherwise, setSourceXML is called on this object, passing in the created document.

Returns:

 

See Also:


getXMLId

String getXMLId()
Returns the XML ID of this object.

Returns:

the XML ID.  

getXMLString

String getXMLString()
Returns the XML string of this object.

Returns:

 

See Also:


getXMLTransformers

Array<String> getXMLTransformers()
Returns the list of XML transformers of this object.

Returns:

 

Since:

3.2

See Also:


getXMLURL

String getXMLURL()
Returns the XML URL of this object.

Returns:

 

getXSL

jsx3.xml.Document getXSL()
Returns the XSL source document of this object. The XSL document is determined by the following steps:
  1. If an XSL document exists in the server cache under an ID equal to the XSL ID of this object, that document is returned.
  2. (Deprecated) If the XSL string of this object is not null, a new document is created by parsing this string.
  3. (Deprecated) If the XSL URL of this object is not null, a new document is created by parsing the file at the location specified by the URL resolved against the server owning this object.
  4. Otherwise, the default stylesheet (Cacheable.DEFAULTSTYLESHEET) is returned.

Returns:

the XSL source document.  

getXSLId

String getXSLId()
Returns the XSL ID of this object.

Returns:

 

See Also:


getXSLParams

Object<String, String> getXSLParams()
Returns a map containing all the parameters to pass to the XSL stylesheet during transformation.

Returns:

 

getXSLString

String getXSLString()
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Returns the XSL string of this object.

Returns:

 

See Also:


getXSLURL

String getXSLURL()
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Returns the XSL URL of this object.

Returns:

 

See Also:


getXmlAsync

int getXmlAsync()
Returns whether the XML data source of this object is loaded asynchronously.

Returns:

0 or 1

Since:

3.5

getXmlBind

int getXmlBind()
Returns whether this object is bound to the XML document stored in the data cache.

Returns:

0 or 1

Since:

3.5

onXmlBinding

protected void onXmlBinding(objEvent : Object)
This method is called in two situations:
  1. When the datasource of this object finishes loading (success, error, or timeout), if the xmlAsync property of this object is true, its datasource is specified as an XML URL, and the first time doTransform() was called the datasource was still loading.
  2. Any time the value stored in the server XML cache under the key equal to the XML Id of this object changes, if the xmlBind property of this object is true.
Any methods overriding this method should begin with a call to jsxsupermix().

Parameters:

objEventthe event published by the cache.

Since:

3.5

removeXSLParam

jsx3.xml.Cacheable removeXSLParam(strName : String)
Removes a parameter from the list of parameters to pass to the XSL stylesheet during transformation.

Parameters:

strNamethe name of the XSL parameter to remove.

Returns:

this object.  

removeXSLParams

jsx3.xml.Cacheable removeXSLParams()
Removes all parameters from the list of parameters to pass to the XSL stylesheet during transformation.

Returns:

this object.  

resetCacheData

void resetCacheData(objServer : jsx3.app.Server)
Removes the XML and XSL source documents from the server cache.

Parameters:

objServerthe server owning the cache to modify. This is a required argument only if this.getServer() does not returns a server instance.

resetData

void resetData()
Deprecated. renamed to clearXmlData()

resetXmlCacheData

void resetXmlCacheData(objServer : jsx3.app.Server)
Removes the XML source document stored under the XML ID of this object from the server cache.

Parameters:

objServerthe server owning the cache to modify. This is a required argument only if this.getServer() does not returns a server instance.

resetXslCacheData

void resetXslCacheData(objServer : jsx3.app.Server)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Removes the XSL source document stored under the XSL ID of this object from the server cache.

Parameters:

objServerthe server owning the cache to modify. This is a required argument only if this.getServer() does not returns a server instance.

See Also:


setNodeSet

void setNodeSet(objNodeSet : jsx3.xml.Entity)
Deprecated.
Sets the node set of this object. If the node set of this object is set by calling this method, the default XSL transformation will use this node set instead of the return value of getXML() as the XML document to transform.

Parameters:

objNodeSet

setShareResources

jsx3.xml.Cacheable setShareResources(intShare : int)
Sets whether this object removes its XML and XSL source documents from the cache of its server when it is destroyed.

Parameters:

intShareCLEANUPRESOURCES or SHARERESOURCES. CLEANUPRESOURCES is the default value if the property is null.

Returns:

this object. 

See Also:

,

setSourceXML

jsx3.xml.Document setSourceXML(objDoc : jsx3.xml.Document, objCache : jsx3.app.Cache)
Sets the source document of this object as though objDoc were retrieved from the XML URL or XML string of this object. This method executes the following steps:
  1. The document is transformed serially by each XML transformers of this object.
  2. The XML document is saved in the server cache under the XML ID of this object.
  3. If this object is an instance of jsx3.xml.CDF and the root node is a <data> element and its jsxassignids attribute is equal to 1, all <record> elements without a jsxid attribute are assigned a unique jsxid.
  4. If this object is an instance of jsx3.xml.CDF, convertProperties() is called on this object.

Parameters:

objDoc
objCache

Returns:

the document stored in the server cache as the data source of this object. If transformers were run, this value will not be equal to the objDoc parameter. 

See Also:


setXMLId

jsx3.xml.Cacheable setXMLId(strXMLId : String)
Sets the XML ID of this object. This value is the key under which the XML source document of this object is saved in the cache of the server owning this object. The developer may specify either a unique or shared value. If no value is specified, a unique id is generated.

Parameters:

strXMLId

Returns:

this object. 

See Also:


setXMLString

jsx3.xml.Cacheable setXMLString(strXML : String)
Sets the XML string of this object. Setting this value to the string serialization of an XML document is one way of specifying the source XML document of this object.

Parameters:

strXMLnull or a well-formed serialized XML element.

Returns:

this object. 

See Also:


setXMLTransformers

void setXMLTransformers(arrTrans : Array<String>)
Sets the list of XML transformers of this object. The XML source document of this object is transformed serially by each of these transformers before it is placed in the XML cache.

Each transformer is either the URI of an XSLT document (which will be resolved against the the server of this object) or the cache id of a XSLT document in the XML cache of the server of this object. When any transformer is loaded from a URI it is placed in the server cache under the id equal to its resolved URI. Any transformer that does not correspond to a valid XSLT document will be skipped without throwing an error.

Parameters:

arrTrans

Since:

3.2

setXMLURL

jsx3.xml.Cacheable setXMLURL(strXMLURL : String)
Sets the XML URL of this object. Settings this value to the URI of an XML document is one way of specifying the source XML document of this object.

Parameters:

strXMLURLnull or a URI that when resolved against the server owning this object specifies a valid XML document.

Returns:

this object. 

See Also:


setXSLId

jsx3.xml.Cacheable setXSLId(strXSLId : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Sets the XSL ID of this object.

Parameters:

strXSLId

Returns:

this object. 

See Also:

,

setXSLParam

jsx3.xml.Cacheable setXSLParam(strName : String, strValue : String)
Adds a name/value pair to the list of parameters to pass to the XSL stylesheet during transformation. If strValue is null the parameter is removed.

Parameters:

strNamethe name of the XSL parameter to add.
strValuethe value of the XSL parameter to add.

Returns:

this object.  

setXSLString

jsx3.xml.Cacheable setXSLString(strXSL : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Sets the XSL string of this object.

Parameters:

strXSL

Returns:

this object. 

See Also:

,

setXSLURL

jsx3.xml.Cacheable setXSLURL(strXSLURL : String)
Deprecated. Per-instance control of the XSL template is deprecated. Consider using the XML transformers functionality instead.
Sets the XSL URL of this object.

Parameters:

strXSLURL

Returns:

this object. 

See Also:

,

setXmlAsync

jsx3.xml.Cacheable setXmlAsync(bAsync : boolean)
Sets whether the XML data source of this object is loaded asynchronously. This setting only applies to data sources loaded from an XML URL.

Parameters:

bAsync

Returns:

this object. 

Since:

3.5

setXmlBind

jsx3.xml.Cacheable setXmlBind(bBind : ?)
Sets whether this object is bound to the XML document stored in the data cache. If this object is bound to the cache, then the onXmlBinding() method of this object is called any time the document stored in the cache under the XML Id of this object changes.

Parameters:

bBind

Returns:

this object. 

Since:

3.5

jsx3.xml

class Document

Object
->jsx3.lang.Object
  ->jsx3.xml.Entity
    ->jsx3.xml.Document

All Implemented Interfaces:

jsx3.util.EventDispatcher

Direct Known Subclasses:

jsx3.xml.CDF.Document, jsx3.xml.XslDocument

class Document
extends jsx3.xml.Entity
Wrapper of the native browser XML document class. Developers wishing to create/modify XML documents should use this class to access common XML parser methods (adding attributes and nodes, transformations, etc).

When querying an instance of this class (with e.g. selectSingleNode, selectNodes, getChildNodes, etc.), the node context will always be the root node (documentElement) and not the parser instance (ownerDocument). Therefore, all queries are assumed to begin at the root, meaning querying an instance of this class for the root node (assuming its name is "Price") would require a query such as "." or "/Price", not "Price".

Note that several methods of this class fail quietly when an error occurs with the wrapped native browser XML classes. Methods that are documented as failing quietly should always be followed by a call to hasError() to ensure that no error has occurred.

See Also:


Field Summary
static String
Event type published when an error occurs during the asynchronous loading of a document.
static String
Event type published when an asynchronous load operation has completed successfully.
static String
Event type published when an asynchronous load times out before loading.
static String
Namespace to use when querying against the namespace axis in firefox
static String
Prefix to use when querying against the namespace axis in firefox
Constructor Summary
void
The instance initializer.
Method Summary
jsx3.xml.Document
Creates a new node that is an exact clone of this node; returns the newly cloned node wrapped in a jsx3.xml.Entity instance
jsx3.xml.Entity
createDocumentElement(strNodeName : String, strNSURI : String)
Creates a new root node on an empty document.
String
The Firefox implementation of the XSLT specification does not implement a searchable namespace axis.
void
createProcessingInstruction(strTarget : String, strData : String)
Creates a processing instruction node that containing the target and data information.
boolean
getAsync(strName : ?)
Returns whether this document loads asynchronously.
Object
Returns a map of all implemented namespaces in the following format: {some_uri:"jsx1",some_other_uri,"jsx2",another_uri:"jsx3"}.
Object
Returns the native XML parser
boolean
Deprecated. IE-only.
String
Deprecated. This method is only implemented on Internet Explorer. XPath is the only supported value.
String
getSelectionNamespaces(strName : ?)
Gets a list of namespace prefixes and their associated URIs.
String
boolean
Deprecated. IE-only.
static String
Deprecated.
String
boolean
String
jsx3.xml.Document
load(strURL : String | jsx3.net.URI, intTimeout : int)
Loads an XML document at the URL specified by the strURL parameter.
jsx3.xml.Document
loadXML(strXML : String)
Loads an XML document from a string containing the XML source.
void
serialize(strVersion : boolean | String, strEncoding : boolean | String, bStandalone : boolean)
jsx3.xml.Document
setAsync(bAsync : boolean)
Sets whether this document loads asynchronously.
void
Deprecated. IE-only.
jsx3.xml.Document
setSelectionLanguage(strLanguage : String)
Deprecated. This method is only implemented on Internet Explorer. XPath is the only supported value.
jsx3.xml.Document
Sets a list of namespace prefixes and their associated URIs.
void
Deprecated. IE-only.
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.xml.Entity
appendChild, cloneNode, createNode, equals, getAttribute, getAttributeNames, getAttributeNode, getAttributes, getBaseName, getChildIterator, getChildNodes, getError, getFirstChild, getLastChild, getNamespaceURI, getNative, getNextSibling, getNodeName, getNodeType, getOwnerDocument, getParent, getPrefix, getPreviousSibling, getRootNode, getValue, getXML, hasError, insertBefore, removeAttribute, removeAttributeNode, removeChild, removeChildren, replaceNode, selectNodeIterator, selectNodes, selectSingleNode, setAttribute, setAttributeNode, setValue, toString, transformNode
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

ON_ERROR

static final String ON_ERROR
Event type published when an error occurs during the asynchronous loading of a document.

ON_RESPONSE

static final String ON_RESPONSE
Event type published when an asynchronous load operation has completed successfully.

ON_TIMEOUT

static final String ON_TIMEOUT
Event type published when an asynchronous load times out before loading.

SEARCHABLE_NAMESPACE

static final String SEARCHABLE_NAMESPACE
Namespace to use when querying against the namespace axis in firefox

SEARCHABLE_PREFIX

static final String SEARCHABLE_PREFIX
Prefix to use when querying against the namespace axis in firefox
Constructor Detail

init

void init(objDoc : Object | jsx3.xml.Entity)
The instance initializer. If an error occurs while instantiating the native browser XML document class, this method sets the error property of this document and returns quietly.

Parameters:

objDocif an Entity then clone the node as a new document. Otherwise, the native browser document object (optional).
Method Detail

cloneDocument

jsx3.xml.Document cloneDocument()
Creates a new node that is an exact clone of this node; returns the newly cloned node wrapped in a jsx3.xml.Entity instance

Returns:

newly cloned MSXML Node object wrapped in a jsx3.xml.Document instance  

createDocumentElement

jsx3.xml.Entity createDocumentElement(strNodeName : String, strNSURI : String)
Creates a new root node on an empty document.

Usage:

var objDoc = new jsx3.xml.Document();
objDoc.createDocumentElement("myRoot");

Parameters:

strNodeNamenode name for the root node
strNSURInamespace (optional). For example, "http:/someURN.com/". Note that if this parameter is used, @strNodeName can be optionally prefixed (i.e., abc:myRoot) to create an explicit namespace prefix.

Returns:

reference to the new node wrapped in a jsx3.xml.Entity instance  

createNamespaceAxis

String createNamespaceAxis()
The Firefox implementation of the XSLT specification does not implement a searchable namespace axis. To overcome this limitation, this method can be called to create a searchable equivalent that is part of the attribute axis. After XML content has been loaded, call this method before calling any other methods on the Document instance in order to ensure proper functioning of subsequent calls. The document can then be queried, using valid XPath syntax to discover the declared namespaces. However, instead of using namespace::xsd, the relevant query would be attribute::jsx_xmlns:xsd, where jsx_xmlns:xsd would resolve to the universal name, {http://xsd.tns.tibco.com/gi/cxf/2006}:xsd. Following this call with getDeclaredNamespaces is useful to resolve the prefix actually used, providing a reverse-lookup to resolve the actual prefix being used. For example, assume objMap is the return object when calling getDeclaredNamespaces. In such a case, the following query can be used to locate the URI for a given namespace prefix, even though Firefox does not support such a construct:

var objMap = someDoc.getDeclaredNamespaces();
var myXpathQuery = "ancestor-or-self::*[attribute::" +
  objMap[jsx3.xml.Document.SEARCHABLE_NAMESPACE] +  ":xsd]/attribute::" +
  objMap[jsx3.xml.Document.SEARCHABLE_NAMESPACE] + ":xsd";
var objNode = someNode.selectSingleNode(myXpathQuery,objMap);

Returns:

prefix used to represent the xmlns. By default the return will be jsx_xmlns. However, if this prefix is already being used by the document instance (i.e., xmlns:jsx_xmlns="?"), the prefix will be incremented as follows: jsx_xmlns0, jsx_xmlns1, jsx_xmlns2, etc, until a unique prefix is found. 

See Also:


createProcessingInstruction

void createProcessingInstruction(strTarget : String, strData : String)
Creates a processing instruction node that containing the target and data information. Note that you cannot specify a namespace with this method.

Usage:

[document].createProcessingInstruction("xml","version=\"1.0\" encoding=\"UTF-8\"");
[document].createDocumentElement("myRoot");

Parameters:

strTargetString that specifies the target part of the processing instruction. This supplies the nodeName property of the new object.
strDataString that specifies the rest of the processing instruction preceding the closing ?> characters. This supplies the nodeValue property for the new object.

getAsync

boolean getAsync(strName : ?)
Returns whether this document loads asynchronously.

Parameters:

strName

Returns:

 

getDeclaredNamespaces

Object getDeclaredNamespaces(objMap : Object)
Returns a map of all implemented namespaces in the following format: {some_uri:"jsx1",some_other_uri,"jsx2",another_uri:"jsx3"}.
The returned object map can then be used to resolve the qualified name (QName) for the nodes in a given query via a reverse lookup. For example:
//open an XML Document (just use one of the sample prototypes that ships with Builder)
var objXML = new jsx3.xml.Document();
objXML.load("GI_Builder/prototypes/Block/Text.xml");
//get an object map of all known selection namespaces
var objMap = objXML.getDeclaredNamespaces();
//construct a qualified query (Note that all nodes in a GI serialization file belong to the namespace, 'urn:tibco.com/v3.0')
var myQualifiedQuery = "//" + objMap["urn:tibco.com/v3.0"] + ":object";
//query the document for the given node.
var objNode = objXML.selectSingleNode(myQualifiedQuery,objMap);
//alert the return
alert(objNode);

Parameters:

objMapOptional. should follow the format {prefix1:1,prefix2:1}. If passed, the returned Object will resolve to any matched prefix, while using arbitrary sequential prefixes (jsx1, jsx2, etc) for all other uris.

Returns:

 

getNativeDocument

Object getNativeDocument()
Returns the native XML parser

Returns:

 

getResolveExternals

boolean getResolveExternals()
Deprecated. IE-only.
Returns whether or not the parser should resolve externally referenced entities. The default setting is false;

Returns:

 

Since:

3.2

getSelectionLanguage

String getSelectionLanguage()
Deprecated. This method is only implemented on Internet Explorer. XPath is the only supported value.
Gets the selection language to use for selection queries (i.e., selectSingleNode/selectNodes); The default is XSLPattern;

Returns:

 

getSelectionNamespaces

String getSelectionNamespaces(strName : ?)
Gets a list of namespace prefixes and their associated URIs. This allows any code to generically prefix name-space qualified nodes and still get the correct selection result

Parameters:

strName

Returns:

 

getSourceURL

String getSourceURL()

Returns:

 

Since:

3.2

getValidateOnParse

boolean getValidateOnParse()
Deprecated. IE-only.
Returns whether or not the parser should validate the XML content during the initial parse. The default setting is false;

Returns:

 

Since:

3.2

getVersion

static String getVersion()
Deprecated.
gets the release/build for the class (i.e., "2.2.00")

Returns:

 

getXmlEncoding

String getXmlEncoding()

Returns:

 

getXmlStandalone

boolean getXmlStandalone()

Returns:

 

getXmlVersion

String getXmlVersion()

Returns:

 

load

jsx3.xml.Document load(strURL : String | jsx3.net.URI, intTimeout : int)
Loads an XML document at the URL specified by the strURL parameter. If an error occurs while loading the XML document, this method sets the error property of this document and returns quietly. If this document loads synchronously, the results of the load will be available immediately after the call to this method. Otherwise, this document publishes events through the EventDispatcher interface to notify the client that loading has completed.

Parameters:

strURLeither a relative or absolute URL pointing to an XML document to load.
intTimeoutthe number of milliseconds to wait before timing out. This parameter is only relevant if this document is loading XML asynchronously. A zero or null value will cause this operation to wait forever.

Returns:

this object. 

See Also:


loadXML

jsx3.xml.Document loadXML(strXML : String)
Loads an XML document from a string containing the XML source. If an error occurs while loading the XML document, this method sets the error property of this document and returns quietly. Loading an XML document from a string always happens synchronously regardless of the value of the async property of this document.

Parameters:

strXMLan XML document as string. Note that if this document contains an encoding attribute in its initial declaration (such as encoding="UTF-8") it must correspond to the encoding of the actual string, strXML. If, for example, strXML is in unicode format, explicitly passing the UTF-8 encoding attribute will cause the load to fail, as the byte order will cause the parser to look for the UTF-16 attribute.

Returns:

this object.  

serialize

void serialize(strVersion : boolean | String, strEncoding : boolean | String, bStandalone : boolean)

Parameters:

strVersion
strEncoding
bStandalone

setAsync

jsx3.xml.Document setAsync(bAsync : boolean)
Sets whether this document loads asynchronously. The default is to load synchronously. If this document loads asynchronously, it publishes the events ON_RESPONSE, ON_ERROR, and ON_TIMEOUT to notify the client that loading has finished.

Parameters:

bAsyncif true the document loads asynchronously.

Returns:

this object. 

See Also:

, ,

setResolveExternals

void setResolveExternals(bResolve : boolean)
Deprecated. IE-only.
Sets whether or not the parser should resolve externally referenced entities.

Parameters:

bResolve

Since:

3.2

setSelectionLanguage

jsx3.xml.Document setSelectionLanguage(strLanguage : String)
Deprecated. This method is only implemented on Internet Explorer. XPath is the only supported value.
Sets the selection language to use for selection queries (i.e., selectSingleNode/selectNodes); The default is XSLPattern;

Parameters:

strLanguageone of the strings: XSLPattern, XPath

Returns:

reference to this 

setSelectionNamespaces

jsx3.xml.Document setSelectionNamespaces(declaration : Object | String)
Sets a list of namespace prefixes and their associated URIs. This allows any code to generically prefix name-space qualified nodes and still get the correct selection result

Parameters:

declarationRelevant selection namespace(s) in Object format. For example: {some_uri:"jsx1",some_other_uri,"jsx2"} or in String format. For example: "xmlns:jsx1='some_uri' xmlns:jsx2='some_other_uri'"

Returns:

reference to this  

setValidateOnParse

void setValidateOnParse(bValidate : boolean)
Deprecated. IE-only.
Sets whether or not the parser should validate the XML content during the initial parse.

Parameters:

bValidate

Since:

3.2

jsx3.xml

class DojoDataStore

Object
->jsx3.lang.Object
  ->jsx3.xml.DojoDataStore

All Implemented Interfaces:

jsx3.xml.CDF

abstract class DojoDataStore
extends jsx3.lang.Object
Provides access to Dojo data store through the CDF interface.

Constructor Summary
void
init(store : Object)
The instance initializer.
Methods Inherited From jsx3.xml.CDF
adoptRecord, adoptRecordBefore, convertProperties, deleteRecord, deleteRecordProperty, getRecord, getRecordIds, getRecordNode, insertRecord, insertRecordBefore, insertRecordNode, insertRecordProperty, redrawRecord, reloadFromSource, resetData
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(store : Object)
The instance initializer.

Parameters:

storethe Dojo data store object.

jsx3.xml

class Entity

Object
->jsx3.lang.Object
  ->jsx3.xml.Entity

Direct Known Subclasses:

jsx3.xml.Document

class Entity
extends jsx3.lang.Object
Wrapper of the native browser XML node class. This class provides methods for querying, traversing, and creating XML entities.

This class is never instantiated by the developer, rather instances are returned from various methods in this class and the jsx3.xml.Document class.

Note that several methods of this class fail quietly when an error occurs with the wrapped native browser XML classes. Methods that are documented as failing quietly should always be followed by a call to hasError() to ensure that no error has occurred.

Field Summary
static int
The node type for an attribute node.
static int
The node type for a character data node.
static int
The node type for a comment node.
static int
The node type for an element node.
static int
The node type for a text node.
Constructor Summary
void
init(objEntity : Object)
The instance initializer.
Method Summary
jsx3.xml.Entity
Appends the objEntity parameter as a child of this entity.
jsx3.xml.Entity
cloneNode(bDeep : boolean)
Creates a new node that is an exact clone of this node.
jsx3.xml.Entity
createNode(intType : int, strNodeName : String, strNS : String)
Creates a new node and returns as jsx3.xml.Entity instance
boolean
equals(objEntity : jsx3.xml.Entity)
Tests the equivalency of two jsx3.xml.Entity instances as they wrap and can therefore point to the same native entity, causing a standard "==" comparison to fail
String
getAttribute(strName : String)
Returns the value for the named attribute strName.
Array<String>
Returns the names of all the attributes of this node.
jsx3.xml.Entity
Returns an object reference (a jsx3.xml.Entity instance) to the child attribute with the name, @strName.
jsx3.util.List<jsx3.xml.Entity>
Returns handle to a jsx3.util.List instance of all children; note that this collection will always be empty (length = 0) for all types except for jsx3.xml.Entity.TYPEELEMENT
String
Returns the right-hand side of a namespace qualified name.
jsx3.util.Iterator<jsx3.xml.Entity>
getChildIterator(bIncludeText : boolean)
Returns an iterator that iterates over the child nodes of this node.
jsx3.util.List<jsx3.xml.Entity>
getChildNodes(bIncludeText : boolean)
Returns the child nodes of this entity.
Object
Returns an error object (a plain JavaScript object) with two properties that the developer can query for: code – an integer error code, 0 for no error.
jsx3.xml.Entity
Returns the first child element of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if both conditions are not met
jsx3.xml.Entity
Returns the last child element of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if both conditions are not met
String
Returns the value (as string) for URI (universal resource identifier) of the namespace for the given node; returns an empty string if no namespace exists
Object
Returns the native browser XML node wrapped by this entity.
jsx3.xml.Entity
Returns the next sibling if this node and the referenced sibling are of type jsx3.xml.Entity.TYPEELEMENT; returns null if condition is not met
String
Returns the name of the node as string (assuming this jsx3.xml.Entity instance is of type jsx3.xml.Entity.TYPEELEMENT or jsx3.xml.Entity.TYPEATTRIBUTE).
int
Returns one of: jsx3.xml.Entity.TYPEELEMENT, jsx3.xml.Entity.TYPEATTRIBUTE, jsx3.xml.Entity.TYPETEXT, jsx3.xml.Entity.TYPECDATA
jsx3.xml.Document
Returns the document that owns this entity.
jsx3.xml.Entity
Returns the parent node of the context node.
String
Returns the left-hand side of a namespace qualified name.
jsx3.xml.Entity
Returns the previous sibling if this node and the referenced sibling are of type jsx3.xml.Entity.TYPEELEMENT; returns null if condition is not met
jsx3.xml.Entity
Returns reference to the document element (root) wrapped in jsx3.xml.Entity instance
String
Contains the text content of the node, including the concatenated text contained by all descendant entities
static String
Deprecated.
String
Deprecated. Use toString() instead.
boolean
Returns true if the last operation on this XML entity caused an error.
jsx3.xml.Entity
insertBefore(objEntityNew : jsx3.xml.Entity, objEntityRef : jsx3.xml.Entity)
inserts the jsx3.xml.Entity instance, @objEntityNew immediately before the existing child @objEntityRef and returns a handle to @objEntityNew; requires that both parameters be of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if all conditions are not met
void
removeAttribute(strAttName : String)
Removes the specified attribute by the given name (can only be called for nodes of type jsx3.xml.Entity.TYPELEMENT)
jsx3.xml.Entity
removes the attribute object as a child of the element;
jsx3.xml.Entity
removeChild(objChildEntity : jsx3.xml.Entity)
Removes the specified child (@objChildEntity) from the list of children and returns it; returns null if @objChildEntity is not actually a child
void
Removes all descendant entities of this node
jsx3.xml.Entity
replaceNode(objEntityNew : jsx3.xml.Entity, objEntityOld : jsx3.xml.Entity)
replaces the child @objEntityOld with @objEntityNew and returns a handle to @objEntityOld; requires that both child entities be of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if all conditions are not met
jsx3.util.Iterator<jsx3.xml.Entity>
selectNodeIterator(strQuery : String, strNS : String | Object)
Returns an iterator that iterates over the the result of an XPath query.
jsx3.util.List<jsx3.xml.Entity>
selectNodes(strQuery : String, strNS : String | Object)
Returns a list of nodes selected by an XPath query executed on this node.
jsx3.xml.Entity
selectSingleNode(strQuery : String, strNS : String | Object)
Returns a single node selected by an XPath query executed on this node, or null if none is selected.
jsx3.xml.Entity
setAttribute(strName : String, strValue : String)
Sets the @strValue of the named @strAttribute and binds as child of this
jsx3.xml.Entity
Sets the attribute object as a child of the element; if transferring an attribute from one element to another, this call must be preceded with removeAttributeNode on the previous owner
jsx3.xml.Entity
setValue(strValue : String)
sets the text value for this entity; returns a handle to this jsx3.xml.Entity instance
String
Returns the XML (as String) for this node and any descendants.
String | jsx3.xml.Document
transformNode(objEntityFilter : jsx3.xml.Entity, objParams : Object<String, String>, bObject : boolean)
performs an XSLT transformation, using @objEntityFilter as the XSLT filter for the transformation; returns results of the transformation as a string (of text/html/xml/etc)
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Field Detail

TYPEATTRIBUTE

static final int TYPEATTRIBUTE
The node type for an attribute node.

TYPECDATA

static final int TYPECDATA
The node type for a character data node.

TYPECOMMENT

static final int TYPECOMMENT
The node type for a comment node.

TYPEELEMENT

static final int TYPEELEMENT
The node type for an element node.

TYPETEXT

static final int TYPETEXT
The node type for a text node.
Constructor Detail

init

void init(objEntity : Object)
The instance initializer. If an error occurs while instantiating this entity, this method sets the error property of this entity and returns quietly.

Parameters:

objEntitythe browser native entity instance to wrap.
Method Detail

appendChild

jsx3.xml.Entity appendChild(objEntity : jsx3.xml.Entity)
Appends the objEntity parameter as a child of this entity. If an error occurs while appending to this XML entity, this method sets the error property of this entity and returns quietly.

Parameters:

objEntityjsx3.xml.Entity instance that will be bound as a child to this jsx3.xml.Entity instance

Returns:

reference to self  

cloneNode

jsx3.xml.Entity cloneNode(bDeep : boolean)
Creates a new node that is an exact clone of this node. If an error occurs while cloning this XML entity, this method sets the error property of this entity and returns quietly.

Parameters:

bDeepif true, all descendants of this object will also be cloned and returned

Returns:

newly cloned MSXML Node object wrapped in a jsx3.xml.Entity instance  

createNode

jsx3.xml.Entity createNode(intType : int, strNodeName : String, strNS : String)
Creates a new node and returns as jsx3.xml.Entity instance

Parameters:

intTypeFour types are supported: jsx3.xml.Entity.TYPEELEMENT, jsx3.xml.Entity.TYPEATTRIBUTE, jsx3.xml.Entity.TYPETEXT, jsx3.xml.Entity.TYPECDATA. Note: only nodes of TYPEELEMENT and TYPEATTRIBUTE will pay attention to the @strNodeName property; if not of this TYPE, pass an empty string
strNodeNamenode name for the node to add as a child
strNSnamespace URI for the node being created, if it is preceded by a URI. So, for example, if 'strName' is "xsi:string", then the 'strNS' value should be the namespace associated with the xsi prefix

Returns:

reference to the new node wrapped in a jsx3.xml.Entity instance  

equals

boolean equals(objEntity : jsx3.xml.Entity)
Tests the equivalency of two jsx3.xml.Entity instances as they wrap and can therefore point to the same native entity, causing a standard "==" comparison to fail

Parameters:

objEntityjsx3.xml.Entity object

Returns:

true or false  

Overrides:


getAttribute

String getAttribute(strName : String)
Returns the value for the named attribute strName.

Parameters:

strNamethe name of the attribute.

Returns:

the attribute value or null if the attribute does not exist.  

getAttributeNames

Array<String> getAttributeNames()
Returns the names of all the attributes of this node. Iterating over the attribute names is more performant than using the getAttributes() method.

Returns:

 

Since:

3.4

See Also:


getAttributeNode

jsx3.xml.Entity getAttributeNode(strName : String)
Returns an object reference (a jsx3.xml.Entity instance) to the child attribute with the name, @strName. This method should only be called on an instance of type TYPEELEMENT.

Parameters:

strNamename of the attribute

Returns:

jsx3.xml.Entity instance referencing a single attribute node object  

getAttributes

jsx3.util.List<jsx3.xml.Entity> getAttributes()
Returns handle to a jsx3.util.List instance of all children; note that this collection will always be empty (length = 0) for all types except for jsx3.xml.Entity.TYPEELEMENT

Returns:

 

See Also:


getBaseName

String getBaseName()
Returns the right-hand side of a namespace qualified name. For example, "Price" will be returned for the element <USD:Price>

Returns:

 

getChildIterator

jsx3.util.Iterator<jsx3.xml.Entity> getChildIterator(bIncludeText : boolean)
Returns an iterator that iterates over the child nodes of this node. Note that the iterator grants access to only one child node at a time; once next() is called, the value returned by the previous call to next() is no longer valid. This method is more performant than getChildNodes().

Note also that the iterator is a pointer into the children node list so removing or adding children to this node while iterating may cause unexpected behavior.

Parameters:

bIncludeTextif true then the returned iterator will include the child text nodes of this node.

Returns:

 

Since:

3.4

See Also:


getChildNodes

jsx3.util.List<jsx3.xml.Entity> getChildNodes(bIncludeText : boolean)
Returns the child nodes of this entity. By default this method only returns the child nodes that are elements. Text and CDATA children will be returned if bIncludeText is true.

Parameters:

bIncludeTextif true, text and cdata children are returned with element children.

Returns:

 

See Also:


getError

Object getError()
Returns an error object (a plain JavaScript object) with two properties that the developer can query for:
  • code – an integer error code, 0 for no error.
  • description – a text description of the error that occurred.

Returns:

 

getFirstChild

jsx3.xml.Entity getFirstChild()
Returns the first child element of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if both conditions are not met

Returns:

jsx3.xml.Entity instance or null  

getLastChild

jsx3.xml.Entity getLastChild()
Returns the last child element of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if both conditions are not met

Returns:

jsx3.xml.Entity instance or null  

getNamespaceURI

String getNamespaceURI()
Returns the value (as string) for URI (universal resource identifier) of the namespace for the given node; returns an empty string if no namespace exists

Returns:

 

getNative

Object getNative()
Returns the native browser XML node wrapped by this entity.

Returns:

 

getNextSibling

jsx3.xml.Entity getNextSibling()
Returns the next sibling if this node and the referenced sibling are of type jsx3.xml.Entity.TYPEELEMENT; returns null if condition is not met

Returns:

jsx3.xml.Entity instance or null  

getNodeName

String getNodeName()
Returns the name of the node as string (assuming this jsx3.xml.Entity instance is of type jsx3.xml.Entity.TYPEELEMENT or jsx3.xml.Entity.TYPEATTRIBUTE). The other TYPES return "#cdata-section" and "#text" respectively

Returns:

 

getNodeType

int getNodeType()
Returns one of: jsx3.xml.Entity.TYPEELEMENT, jsx3.xml.Entity.TYPEATTRIBUTE, jsx3.xml.Entity.TYPETEXT, jsx3.xml.Entity.TYPECDATA

Returns:

 

getOwnerDocument

jsx3.xml.Document getOwnerDocument()
Returns the document that owns this entity.

Returns:

 

getParent

jsx3.xml.Entity getParent()
Returns the parent node of the context node. If the context node is the root node of the document, null is returned.

Returns:

parent node or null  

getPrefix

String getPrefix()
Returns the left-hand side of a namespace qualified name. For example, "USD" will be returned for the element <USD:Price>

Returns:

 

getPreviousSibling

jsx3.xml.Entity getPreviousSibling()
Returns the previous sibling if this node and the referenced sibling are of type jsx3.xml.Entity.TYPEELEMENT; returns null if condition is not met

Returns:

jsx3.xml.Entity instance or null  

getRootNode

jsx3.xml.Entity getRootNode()
Returns reference to the document element (root) wrapped in jsx3.xml.Entity instance

Returns:

jsx3.xml.Entity instance  

getValue

String getValue()
Contains the text content of the node, including the concatenated text contained by all descendant entities

Returns:

 

getVersion

static String getVersion()
Deprecated.
Returns the release/build for the class (i.e., "2.2.00")

Returns:

 

getXML

String getXML()
Deprecated. Use toString() instead.
Returns the XML (as String) for this node and any descendants. For an attribute this would be the attribute name and value (i.e., name="value")

Returns:

 

See Also:


hasError

boolean hasError()
Returns true if the last operation on this XML entity caused an error.

Returns:

 

insertBefore

jsx3.xml.Entity insertBefore(objEntityNew : jsx3.xml.Entity, objEntityRef : jsx3.xml.Entity)
inserts the jsx3.xml.Entity instance, @objEntityNew immediately before the existing child @objEntityRef and returns a handle to @objEntityNew; requires that both parameters be of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if all conditions are not met

Parameters:

objEntityNewjsx3.xml.Entity object (the new one to add)
objEntityRefjsx3.xml.Entity object (the reference node in front of which to insert the new node)

Returns:

jsx3.xml.Entity instance or null  

removeAttribute

void removeAttribute(strAttName : String)
Removes the specified attribute by the given name (can only be called for nodes of type jsx3.xml.Entity.TYPELEMENT)

Parameters:

strAttNamethe name of the attribute to remove

removeAttributeNode

jsx3.xml.Entity removeAttributeNode(objAtt : jsx3.xml.Entity)
removes the attribute object as a child of the element;

Parameters:

objAttjsx3.xml.Entity instance of type jsx3.xml.Entity.TYPEATTRIBUTE;

Returns:

reference to this  

removeChild

jsx3.xml.Entity removeChild(objChildEntity : jsx3.xml.Entity)
Removes the specified child (@objChildEntity) from the list of children and returns it; returns null if @objChildEntity is not actually a child

Parameters:

objChildEntityjsx3.xml.Entity object that is a direct child of this jsx3.xml.Entity instance

Returns:

jsx3.xml.Entity instance or null  

removeChildren

void removeChildren()
Removes all descendant entities of this node

replaceNode

jsx3.xml.Entity replaceNode(objEntityNew : jsx3.xml.Entity, objEntityOld : jsx3.xml.Entity)
replaces the child @objEntityOld with @objEntityNew and returns a handle to @objEntityOld; requires that both child entities be of type jsx3.xml.Entity.TYPEELEMENT; requires that this object also be of TYPEELEMENT; returns null if all conditions are not met

Parameters:

objEntityNewjsx3.xml.Entity object (the new one to add)
objEntityOldjsx3.xml.Entity object (the old one to remove)

Returns:

jsx3.xml.Entity instance or null  

selectNodeIterator

jsx3.util.Iterator<jsx3.xml.Entity> selectNodeIterator(strQuery : String, strNS : String | Object)
Returns an iterator that iterates over the the result of an XPath query. Note that the iterator grants access to only one child node at a time; once next() is called, the value returned by the previous call to next() is no longer valid. This method is more performant than selectNodes().

Parameters:

strQueryan XPath query such as: //somenode[@id='12']/somechild.
strNSthe selection namespace to use just for this query. This parameter is an optional shortcut for calling setSelectionNamespaces() on the owning document. The format of this parameter as a string is "xmlns:ns1='uri1' xmlns:ns2='uri2'" or as an object is {'uri1':'ns1', 'uri2':'ns2'}.

Returns:

 

Since:

3.4

See Also:


selectNodes

jsx3.util.List<jsx3.xml.Entity> selectNodes(strQuery : String, strNS : String | Object)
Returns a list of nodes selected by an XPath query executed on this node.

Parameters:

strQueryan XPath query such as: //somenode[@id='12']/somechild.
strNSthe selection namespace to use just for this query. This parameter is an optional shortcut for calling setSelectionNamespaces() on the owning document. The format of this parameter as a string is "xmlns:ns1='uri1' xmlns:ns2='uri2'" or as an object is {'uri1':'ns1', 'uri2':'ns2'}.

Returns:

 

See Also:

,

selectSingleNode

jsx3.xml.Entity selectSingleNode(strQuery : String, strNS : String | Object)
Returns a single node selected by an XPath query executed on this node, or null if none is selected.

Note that the XPath query is executed in the context of this node so relative paths are relative to this node. However, this node may be nested in a larger XML document, in which case absolute paths are relative to the root document of this node. This behavior matches the XPath specification.

Parameters:

strQueryan XPath query such as: //somenode[@id='12']/somechild.
strNSthe selection namespace to use just for this query. This parameter is an optional shortcut for calling setSelectionNamespaces() on the owning document. The format of this parameter as a string is "xmlns:ns1='uri1' xmlns:ns2='uri2'" or as an object is {'uri1':'ns1', 'uri2':'ns2'}.

Returns:

jsx3.xml.Entity instance or null  

setAttribute

jsx3.xml.Entity setAttribute(strName : String, strValue : String)
Sets the @strValue of the named @strAttribute and binds as child of this

Parameters:

strNamename of the attribute
strValuevalue of the attribute, if null then remove the attribute

Returns:

reference to this  

setAttributeNode

jsx3.xml.Entity setAttributeNode(objAtt : jsx3.xml.Entity)
Sets the attribute object as a child of the element; if transferring an attribute from one element to another, this call must be preceded with removeAttributeNode on the previous owner

Parameters:

objAttjsx3.xml.Entity instance of type jsx3.xml.Entity.TYPEATTRIBUTE;

Returns:

reference to this  

setValue

jsx3.xml.Entity setValue(strValue : String)
sets the text value for this entity; returns a handle to this jsx3.xml.Entity instance

Parameters:

strValuevalue to set for this entity

Returns:

self  

toString

String toString()
Returns the XML (as String) for this node and any descendants. For an attribute this would be the attribute name and value (i.e., name="value")

Returns:

 

Overrides:


transformNode

String | jsx3.xml.Document transformNode(objEntityFilter : jsx3.xml.Entity, objParams : Object<String, String>, bObject : boolean)
performs an XSLT transformation, using @objEntityFilter as the XSLT filter for the transformation; returns results of the transformation as a string (of text/html/xml/etc)

Parameters:

objEntityFilterjsx3.xml.Entity instance containing the XSLT document to transform 'this' jsx3.xml.Entity instance with
objParamsJavaScript object array of name/value pairs; if passed, the transformation will use a paramaterized stylesheet to perform the transformation
bObjectif true this method returns a document instead of a string.

Returns:

the result of the transformation  

jsx3.xml

class Processor

Object
->jsx3.lang.Object
  ->jsx3.xml.Processor

class Processor
extends jsx3.lang.Object
Deprecated. Use jsx3.xml.Template instead.
Wrapper of the native browser XSLT processor.

See Also:

jsx3.xml.Template

Constructor Summary
void
init(objXML : jsx3.xml.Entity, objXSL : jsx3.xml.Document, objParams : Object<String, String>)
The instance initializer.
Method Summary
Object
Returns an error object (a plain JavaScript object) with two properties that the developer can query for: code – an integer error code, 0 for no error.
boolean
Returns true if the last operation on this XML entity caused an error.
jsx3.xml.Processor
setParams(objParams : Object<String, String>)
Sets reference to Params that should be passed to the processor.
Object
Sets the XML that should be transformed.
jsx3.xml.Processor
Sets reference to XSL that should be transformed.
String
transform(bObject : boolean)
Performs an XSLT merge.
jsx3.xml.Document
Performs an XSLT merge.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objXML : jsx3.xml.Entity, objXSL : jsx3.xml.Document, objParams : Object<String, String>)
The instance initializer.

Parameters:

objXMLthe source document to transform
objXSLa valid XSL Stylesheet (version 1.0 of "http://www.w3.org/1999/XSL/Transform")
objParamsJavaScript associative array of name/value pairs. If this parameter if provided the transformation will use a paramaterized stylesheet to perform the transformation.
Method Detail

getError

Object getError()
Returns an error object (a plain JavaScript object) with two properties that the developer can query for:
  • code – an integer error code, 0 for no error.
  • description – a text description of the error that occurred.

Returns:

 

hasError

boolean hasError()
Returns true if the last operation on this XML entity caused an error.

Returns:

 

setParams

jsx3.xml.Processor setParams(objParams : Object<String, String>)
Sets reference to Params that should be passed to the processor.

Parameters:

objParamsJavaScript object array of name/value pairs. If this parameter is not empty, the transformation will use a paramaterized stylesheet to perform the transformation.

Returns:

reference to self  

setXML

Object setXML(objXML : jsx3.xml.Entity)
Sets the XML that should be transformed.

Parameters:

objXML

Returns:

this object.  

setXSL

jsx3.xml.Processor setXSL(objXSL : jsx3.xml.Document)
Sets reference to XSL that should be transformed.

Parameters:

objXSLinstance containing a valid XSL Stylesheet (version 1.0 of "http://www.w3.org/1999/XSL/Transform")

Returns:

reference to self  

transform

String transform(bObject : boolean)
Performs an XSLT merge. If an error occurs while performing the transform, this method sets the error property of this processor and returns null.

Parameters:

bObjectif true, a jsx3.xml.Document instance is returned (not the string)

Returns:

the result of the transformation  

transformToObject

jsx3.xml.Document transformToObject()
Performs an XSLT merge. If an error occurs while performing the transform, this method sets the error property of this processor and returns null.

Returns:

if a valid result tree is formed as a result of the transformation  

jsx3.xml

class Template

Object
->jsx3.lang.Object
  ->jsx3.xml.Template

class Template
extends jsx3.lang.Object
Wrapper of the native browser XSLT processor.

Since:

3.4

Constructor Summary
void
The instance initializer.
Method Summary
Object
Returns an error object (a plain JavaScript object) with two properties that the developer can query for: code – an integer error code, 0 for no error.
boolean
Returns true if the last operation on this XML entity caused an error.
void
void
setParam(strName : String, objValue : Object)
void
setParams(objParams : Object<String, Object>)
String
transform(objXML : jsx3.xml.Entity, bObject : boolean)
Performs an XSLT merge.
jsx3.xml.Document
Performs an XSLT merge.
Methods Inherited From jsx3.lang.Object
clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString
Constructor Detail

init

void init(objXSL : jsx3.xml.Document)
The instance initializer.

Parameters:

objXSL

Throws:

{jsx3.lang.Exception}if objXSL is not a valid XML document.
Method Detail

getError

Object getError()
Returns an error object (a plain JavaScript object) with two properties that the developer can query for:
  • code – an integer error code, 0 for no error.
  • description – a text description of the error that occurred.

Returns:

 

hasError

boolean hasError()
Returns true if the last operation on this XML entity caused an error.

Returns:

 

reset

void reset()

setParam

void setParam(strName : String, objValue : Object)

Parameters:

strName
objValue

setParams

void setParams(objParams : Object<String, Object>)

Parameters:

objParamsJavaScript object array of name/value pairs. If this parameter is not empty, the transformation will use a paramaterized stylesheet to perform the transformation.

transform

String transform(objXML : jsx3.xml.Entity, bObject : boolean)
Performs an XSLT merge. If an error occurs while performing the transform, this method sets the error property of this processor and returns null.

Parameters:

objXML
bObject

Returns:

the result of the transformation  

transformToObject

jsx3.xml.Document transformToObject(objXML : jsx3.xml.Entity)
Performs an XSLT merge. If an error occurs while performing the transform, this method sets the error property of this processor and returns null.

Parameters:

objXML

Returns:

if a valid result tree is formed as a result of the transformation  

jsx3.xml

class XslDocument

Object
->jsx3.lang.Object
  ->jsx3.xml.Entity
    ->jsx3.xml.Document
      ->jsx3.xml.XslDocument

All Implemented Interfaces:

jsx3.util.EventDispatcher

class XslDocument
extends jsx3.xml.Document
An extension of jsx3.xml.Document that encapsulates a compiled XSL template.

Method Summary
void
void
setParam(strName : String, objValue : Object)
void
setParams(objParams : Object<String, Object>)
void
void
static jsx3.xml.XslDocument
Methods Inherited From jsx3.xml.Document
cloneDocument, createDocumentElement, createNamespaceAxis, createProcessingInstruction, getAsync, getDeclaredNamespaces, getNativeDocument, getResolveExternals, getSelectionLanguage, getSelectionNamespaces, getSourceURL, getValidateOnParse, getXmlEncoding, getXmlStandalone, getXmlVersion, load, loadXML, serialize, setAsync, setResolveExternals, setSelectionLanguage, setSelectionNamespaces, setValidateOnParse
Methods Inherited From jsx3.util.EventDispatcher
publish, subscribe, unsubscribe, unsubscribeAll
Methods Inherited From jsx3.xml.Entity
appendChild, cloneNode, createNode, equals, getAttribute, getAttributeNames, getAttributeNode, getAttributes, getBaseName, getChildIterator, getChildNodes, getError, getFirstChild, getLastChild, getNamespaceURI, getNative, getNextSibling, getNodeName, getNodeType, getOwnerDocument, getParent, getPrefix, getPreviousSibling, getRootNode, getValue, getXML, hasError, insertBefore, removeAttribute, removeAttributeNode, removeChild, removeChildren, replaceNode, selectNodeIterator, selectNodes, selectSingleNode, setAttribute, setAttributeNode, setValue, toString, transformNode
Methods Inherited From jsx3.lang.Object
clone, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf
Method Detail

reset

void reset()

See Also:


setParam

void setParam(strName : String, objValue : Object)

Parameters:

strName
objValue

See Also:


setParams

void setParams(objParams : Object<String, Object>)

Parameters:

objParams

See Also:


transform

void transform(objXML : jsx3.xml.Entity)

Parameters:

objXML

See Also:


transformToObject

void transformToObject(objXML : jsx3.xml.Entity)

Parameters:

objXML

See Also:


wrap

static jsx3.xml.XslDocument wrap(objXML : jsx3.xml.Document)

Parameters:

objXML

Returns:

 

package window

Top-Level properties and functions. Members in this package are accessed either without a namespace prefix or with the window. prefix.

Class Summary
Array
Native JavaScript class Array.
Boolean
Native JavaScript class Boolean.
Date
Native JavaScript class Date.
Function
Native JavaScript class Function.
HTMLDocument
Native browser DOM class HTMLDocument.
HTMLElement
Native browser DOM class HTMLElement.
Math
Native JavaScript class Math.
Number
Native JavaScript class Number.
Object
Native JavaScript class Object.
RegExp
Native JavaScript class RegExp.
String
Native JavaScript class String.
inheritance
Deprecated. Renamed to jsx3.lang.Object
Field Summary
native static void
native static void
native static void
Method Summary
static void
doDefine(strClassName : String, anonymousFunction : String)
Deprecated. Create classes using jsx3.Class.
static void
doImplement(subClass : String, superClass : String)
Deprecated. Create classes using jsx3.Class.
static void
doInherit(subClass : String, superClass : String, bImplement : boolean)
Deprecated. Create classes using jsx3.Class.
static void
doMixin(objInstance : Object, strClassName : String)
Deprecated. Use jsx3.Class.mixin().
native static void
native static void
native static void
native static void
native static void
native static void
native static void
Field Detail

Infinity

native static ? Infinity

NaN

native static ? NaN

undefined

native static ? undefined
Method Detail

doDefine

static void doDefine(strClassName : String, anonymousFunction : String)
Deprecated. Create classes using jsx3.Class.
Registers all prototype functions and properties, contained by the inner function @anonymousFunction; used by jsx3.Object

Parameters:

strClassNamenamed class containing the anonymous function to call
anonymousFunctioninner function containing named prototypes to bind

See Also:


doImplement

static void doImplement(subClass : String, superClass : String)
Deprecated. Create classes using jsx3.Class.
Transfers prototype methods from one class to another.

Parameters:

subClassnamed subclass to transfer prototypes to
superClassnamed superclass to transfer prototypes from

Returns:

the eval value of the script 

See Also:


doInherit

static void doInherit(subClass : String, superClass : String, bImplement : boolean)
Deprecated. Create classes using jsx3.Class.
Transfers prototype methods from one class to another; establishes @superClass as the super for @subClass.

Parameters:

subClassnamed subclass to transfer prototypes to
superClassnamed superclass to transfer prototypes from
bImplementif true, @superClass is an interface

Returns:

the eval value of the script 

See Also:


doMixin

static void doMixin(objInstance : Object, strClassName : String)
Deprecated. Use jsx3.Class.mixin().
Transfers the methods of a class to a object instance.

Parameters:

objInstanceany JavaScript object
strClassNamethe name of a class

See Also:


escape

native static void escape()

eval

native static void eval()

isFinite

native static void isFinite()

isNaN

native static void isNaN()

parseFloat

native static void parseFloat()

parseInt

native static void parseInt()

unescape

native static void unescape()

window

class Array

Object
->Array

Direct Known Subclasses:

jsx3.$Array

native class Array
extends Object
Native JavaScript class Array. Includes GI extensions.

Field Summary
native int
An unsigned, 32-bit integer that specifies the number of elements in an array.
Constructor Summary
native void
Method Summary
Array
Deprecated. Use the jsx3.util.List class.
native Array
concat(array : Array...)
Joins two or more arrays and returns a new array.
void
contains(objElement : ?)
Deprecated. Use the jsx3.util.List class.
boolean
Deprecated. Use the jsx3.util.List class.
Array
filter(fctFilter : Function)
Deprecated. Use the jsx3.util.List class.
int
indexOf(objElement : Object, intStartAt : int)
Deprecated. Use the jsx3.util.List class.
native String
join(separator : String)
Joins all elements of an array into a string.
int
lastIndexOf(objElement : Object, intStartAt : int)
Deprecated. Use the jsx3.util.List class.
Array | Object
map(fctMapper : Function, bExpand : boolean, bObject : boolean)
Deprecated. Use the jsx3.util.List class.
native Object
pop()
Removes the last element from an array and returns that element.
native int
push(element : Object...)
Adds one or more elements to the end of an array and returns the new length of the array.
void
pushAll(a : Array)
Deprecated. Use the jsx3.util.List class.
void
remove(objElement : ?)
Deprecated. Use the jsx3.util.List class.
native void
Transposes the elements of an array: the first array element becomes the last and the last becomes the first.
native Object
Removes the first element from an array and returns that element.
native Array
slice(begin : int, end : int)
Extracts a section of an array and returns a new array.
native void
sort(compareFunction : Function)
Sorts the elements of an array.
native Array
splice(index : int, howMany : int, element : Object...)
Changes the content of an array, adding new elements while removing old elements.
native String
Returns a string representing the specified array and its elements.
native int
unshift(element : Object...)
Adds one or more elements to the beginning of an array and returns the new length of the array.
Field Detail

length

native int length
An unsigned, 32-bit integer that specifies the number of elements in an array.
Constructor Detail

Array

native void Array()
Method Detail

clone

Array clone()
Deprecated. Use the jsx3.util.List class.
creates a copy of this array

Returns:

 

concat

native Array concat(array : Array...)
Joins two or more arrays and returns a new array.

Parameters:

array

Returns:

 

contains

void contains(objElement : ?)
Deprecated. Use the jsx3.util.List class.

Parameters:

objElement

contentsEqual

boolean contentsEqual(a : Array)
Deprecated. Use the jsx3.util.List class.
Returns true if this array and a have the same length and this[n] = a[n] for all n.

Parameters:

a

Returns:

 

filter

Array filter(fctFilter : Function)
Deprecated. Use the jsx3.util.List class.
Creates a new array with the filtered contents of this array. The fctFilter parameter defines the filtering function.

Parameters:

fctFiltera function that is called once for each item in this array and returns true if the item should be included in the filtered list. The signature of this function is function(item : Object) : boolean.

Returns:

 

Since:

3.1

indexOf

int indexOf(objElement : Object, intStartAt : int)
Deprecated. Use the jsx3.util.List class.
Returns the index of the first occurrence of objElement in this array.

Parameters:

objElementthe item to find
intStartAt

Returns:

the index of the found object or -1 if not found 

join

native String join(separator : String)
Joins all elements of an array into a string.

Parameters:

separator

Returns:

 

lastIndexOf

int lastIndexOf(objElement : Object, intStartAt : int)
Deprecated. Use the jsx3.util.List class.
Returns the index of the last occurrence of objElement in this array.

Parameters:

objElementthe item to find
intStartAt

Returns:

the index of the found object or -1 if not found 

map

Array | Object map(fctMapper : Function, bExpand : boolean, bObject : boolean)
Deprecated. Use the jsx3.util.List class.
Creates a new array with the mapped contents of this array. The fctMapper parameter defines the mapping function.

This method has four modes corresponding to the four possible values for {bExpand, bObject}:
  • {false, false} (default) – the filtering function takes an item in this list and returns a single object value which will take the place of the item in the mapped result.
  • {true, false} – the filtering function takes an item in this list and returns a single object value or an array of values, all of which will be inserted into the mapped result at the index of the item.
  • {false, true} – the filtering function takes an item in this list and returns an array with exactly two values, which become a name/value pair in the mapped result.
  • {true, true} – the filtering function takes an item in this list and returns an array with zero or an even number of items, which become name/value pairs in the mapped result.

Parameters:

fctMappera function that is called once for each item in this array and returns the mapped value. The signature of this function depends on the values for the bExpand and bObject parameters.
bExpandif true, the resulting mapped array or object may any number of values corresponding to each item in this list. Otherwise, it will have exactly one value for each item in this list.
bObjectif true, this array is mapped to an object with property name/value pairs. Otherwise this array is mapped to another array.

Returns:

an Array if the bObject parameter is null or false, otherwise an Object

Since:

3.1

pop

native Object pop()
Removes the last element from an array and returns that element. This method changes the length of the array.

Returns:

 

push

native int push(element : Object...)
Adds one or more elements to the end of an array and returns the new length of the array. This method changes the length of the array.

Parameters:

element

Returns:

the new length of the array 

pushAll

void pushAll(a : Array)
Deprecated. Use the jsx3.util.List class.
pushes the contents of an Array onto this Array.

Parameters:

a

remove

void remove(objElement : ?)
Deprecated. Use the jsx3.util.List class.
removes the first occurrence of objElement in this array

Parameters:

objElementthe object to remove

Returns:

the removed object or null if no object was removed 

reverse

native void reverse()
Transposes the elements of an array: the first array element becomes the last and the last becomes the first.

shift

native Object shift()
Removes the first element from an array and returns that element. This method changes the length of the array.

Returns:

 

slice

native Array slice(begin : int, end : int)
Extracts a section of an array and returns a new array.
  • slice extracts up to but not including end. slice(1,4) extracts the second element through the fourth element (elements indexed 1, 2, and 3)
  • As a negative index, end indicates an offset from the end of the sequence. slice(2,-1) extracts the third element through the second to last element in the sequence.
  • If end is omitted, slice extracts to the end of the sequence.

Parameters:

beginZero-based index at which to begin extraction.
endZero-based index at which to end extraction.

Returns:

 

sort

native void sort(compareFunction : Function)
Sorts the elements of an array.

If compareFunction is supplied, the array elements are sorted according to the return value of the compare function. If a and b are two elements being compared, then:
  • If compareFunction(a, b) is less than 0, sort b to a lower index than a.
  • If compareFunction(a, b) returns 0, leave a and b unchanged with respect to each other, but sorted with respect to all different elements.
  • If compareFunction(a, b) is greater than 0, sort b to a higher index than a.

Parameters:

compareFunctionSpecifies a function that defines the sort order. If omitted, the array is sorted lexicographically (in dictionary order) according to the string conversion of each element.

splice

native Array splice(index : int, howMany : int, element : Object...)
Changes the content of an array, adding new elements while removing old elements.

Parameters:

indexIndex at which to start changing the array.
howManyAn integer indicating the number of old array elements to remove. If howMany is 0, no elements are removed. In this case, you should specify at least one new element.
elementThe elements to add to the array. If you don't specify any elements, splice simply removes elements from the array.

Returns:

an array containing the removed elements 

toString

native String toString()
Returns a string representing the specified array and its elements.

Returns:

 

Overrides:


unshift

native int unshift(element : Object...)
Adds one or more elements to the beginning of an array and returns the new length of the array.

Parameters:

element

Returns:

the new length of the array 

window

class Boolean

Object
->Boolean

native class Boolean
extends Object
Native JavaScript class Boolean.

Methods Inherited From Object
toString

window

class Date

Object
->Date

native class Date
extends Object
Native JavaScript class Date. Includes GI extensions.

Constructor Summary
native void
Method Summary
int
Deprecated.
void
equals(o : Date)
Deprecated.
native void
native void
native void
native void
int
Deprecated.
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native static void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
native void
Methods Inherited From Object
toString
Constructor Detail

Date

native void Date()
Method Detail

compareTo

int compareTo(d : Date)
Deprecated.
compare this date instance to argument d

Parameters:

dthe date to compare this date against

Returns:

1 if this date is later than d, 0 if equal, and -1 otherwise 

equals

void equals(o : Date)
Deprecated.
whether two Date objects represent the same date

Parameters:

othe date to compare this date against

getDate

native void getDate()

getDay

native void getDay()

getFullYear

native void getFullYear()

getHours

native void getHours()

getLastDateOfMonth

int getLastDateOfMonth()
Deprecated.
Returns the date of the last day of the month of this Date object, ie will return 31 for any Date with a January month value (any year and any date)

Returns:

 

getMilliseconds

native void getMilliseconds()

getMinutes

native void getMinutes()

getMonth

native void getMonth()

getSeconds

native void getSeconds()

getTime

native void getTime()

getTimezoneOffset

native void getTimezoneOffset()

getUTCDate

native void getUTCDate()

getUTCDay

native void getUTCDay()

getUTCFullYear

native void getUTCFullYear()

getUTCHours

native void getUTCHours()

getUTCMilliseconds

native void getUTCMilliseconds()

getUTCMinutes

native void getUTCMinutes()

getUTCMonth

native void getUTCMonth()

getUTCSeconds

native void getUTCSeconds()

getYear

native void getYear()

parse

native static void parse()

setDate

native void setDate()

setFullYear

native void setFullYear()

setHours

native void setHours()

setMilliseconds

native void setMilliseconds()

setMinutes

native void setMinutes()

setMonth

native void setMonth()

setSeconds

native void setSeconds()

setTime

native void setTime()

setUTCDate

native void setUTCDate()

setUTCFullYear

native void setUTCFullYear()

setUTCHours

native void setUTCHours()

setUTCMilliseconds

native void setUTCMilliseconds()

setUTCMinutes

native void setUTCMinutes()

setUTCMonth

native void setUTCMonth()

setUTCSeconds

native void setUTCSeconds()

toGMTString

native void toGMTString()

toLocaleString

native void toLocaleString()

toUTCString

native void toUTCString()

window

class Function

Object
->Function

native class Function
extends Object
Native JavaScript class Function.

Constructor Summary
native void
Method Summary
native Object
apply(thisArg : Object, args : Object...)
native Object
call(args : Object...)
Methods Inherited From Object
toString
Constructor Detail

Function

native void Function()
Method Detail

apply

native Object apply(thisArg : Object, args : Object...)

Parameters:

thisArg
args

Returns:

 

call

native Object call(args : Object...)

Parameters:

args

Returns:

 

window

class HTMLDocument

Object
->HTMLElement
  ->HTMLDocument

native class HTMLDocument
extends HTMLElement
Native browser DOM class HTMLDocument. Mozilla browsers call this HTMLDocument, while Microsoft Internet Explorer usually reports it as a plain Object.

Fields Inherited From HTMLElement
childNodes, className, firstChild, id, innerHTML, lastChild, nextSibling, ownerDocument, parentNode, previousSibling, style, tagName
Method Summary
native HTMLElement
Methods Inherited From HTMLElement
getAttribute, removeAttribute, setAttribute
Methods Inherited From Object
toString
Method Detail

getElementById

native HTMLElement getElementById(strId : String)

Parameters:

strId

Returns:

 

window

class HTMLElement

Object
->HTMLElement

Direct Known Subclasses:

HTMLDocument

native class HTMLElement
extends Object
Native browser DOM class HTMLElement. Mozilla browsers call this HTMLElement, while Microsoft Internet Explorer usually reports it as a plain Object.

Field Summary
native Array<HTMLElement>
native String
native HTMLElement
native String
native String
native HTMLElement
native HTMLElement
native HTMLDocument
native HTMLElement
native HTMLElement
native Object
native String
Method Summary
native String
getAttribute(strName : String)
native void
removeAttribute(strName : String)
native void
setAttribute(strName : String, strValue : String)
Methods Inherited From Object
toString
Field Detail

childNodes

native Array<HTMLElement> childNodes

className

native String className

firstChild

native HTMLElement firstChild

id

native String id

innerHTML

native String innerHTML

lastChild

native HTMLElement lastChild

nextSibling

native HTMLElement nextSibling

ownerDocument

native HTMLDocument ownerDocument

parentNode

native HTMLElement parentNode

previousSibling

native HTMLElement previousSibling

style

native Object style

tagName

native String tagName
Method Detail

getAttribute

native String getAttribute(strName : String)

Parameters:

strName

Returns:

 

removeAttribute

native void removeAttribute(strName : String)

Parameters:

strName

setAttribute

native void setAttribute(strName : String, strValue : String)

Parameters:

strName
strValue

window

class Math

Object
->Math

native class Math
extends Object
Native JavaScript class Math. Includes GI extensions.

Field Summary
native static Number
native static Number
native static Number
native static Number
native static Number
native static Number
native static Number
native static Number
Method Summary
native static void
abs()
native static void
native static void
native static void
native static void
native static void
native static void
cos()
native static void
exp()
native static void
static boolean
isNaN(value : Object)
Deprecated. Use jsx3.util.numIsNaN() instead.
native static void
log()
native static void
max()
native static void
min()
static Number
modpos(v : Number, mod : Number)
Deprecated. Use jsx3.util.numMod() instead.
native static void
pow()
native static void
native static void
native static void
sin()
native static void
native static void
tan()
Methods Inherited From Object
toString
Field Detail

E

native static Number E

LN10

native static Number LN10

LN2

native static Number LN2

LOG10E

native static Number LOG10E

LOG2E

native static Number LOG2E

PI

native static Number PI

SQRT1_2

native static Number SQRT1_2

SQRT2

native static Number SQRT2
Method Detail

abs

native static void abs()

acos

native static void acos()

asin

native static void asin()

atan

native static void atan()

atan2

native static void atan2()

ceil

native static void ceil()

cos

native static void cos()

exp

native static void exp()

floor

native static void floor()

isNaN

static boolean isNaN(value : Object)
Deprecated. Use jsx3.util.numIsNaN() instead.
value == null || isNaN(value)

Parameters:

valueany value

Returns:

 

log

native static void log()

max

native static void max()

min

native static void min()

modpos

static Number modpos(v : Number, mod : Number)
Deprecated. Use jsx3.util.numMod() instead.
calculates a mod b, but the result is not allowed to be negative

Parameters:

va
modb

Returns:

a mod b if a >= 0, b + a mod b, if a < 0 

pow

native static void pow()

random

native static void random()

round

native static void round()

sin

native static void sin()

sqrt

native static void sqrt()

tan

native static void tan()

window

class Number

Object
->Number

native class Number
extends Object
Native JavaScript class Number. Includes GI extensions.

Field Summary
native static Number
native static Number
native static Number
native static Number
native static Number
Constructor Summary
native void
Method Summary
Number
roundTo(intUnit : int)
Deprecated. Use jsx3.util.numRound() instead.
native void
native void
String
zeroPad(intDigits : int)
Deprecated. Use the jsx3.util.NumberFormat class.
Methods Inherited From Object
toString
Field Detail

MAX_VALUE

native static Number MAX_VALUE

MIN_VALUE

native static Number MIN_VALUE

NEGATIVE_INFINITY

native static Number NEGATIVE_INFINITY

NaN

native static Number NaN

POSITIVE_INFINITY

native static Number POSITIVE_INFINITY
Constructor Detail

Number

native void Number()
Method Detail

roundTo

Number roundTo(intUnit : int)
Deprecated. Use jsx3.util.numRound() instead.
Rounds the number (this) to the nearest value that can be divided by @intUnit.

Parameters:

intUnitunit to use

Returns:

 

toFixed

native void toFixed()

toPrecision

native void toPrecision()

zeroPad

String zeroPad(intDigits : int)
Deprecated. Use the jsx3.util.NumberFormat class.
Left pads this number with zeros to return a string of length intDigits.

Parameters:

intDigitsthe length of the string to return

Returns:

 

window

class Object

Object

Direct Known Subclasses:

Array, Boolean, Date, Function, HTMLElement, Math, Number, RegExp, String, jsx3.$AsyncCB, jsx3.$AsyncRV, jsx3.$Function, jsx3.$Object, jsx3.lang.ClassLoader, jsx3.lang.Object, jsx3.util.GNode, jsx3.util.Graph, jsx3.util.JobGraph

native class Object
Native JavaScript class Object.

Constructor Summary
native void
Method Summary
native String
Constructor Detail

Object

native void Object()
Method Detail

toString

native String toString()

Returns:

 

window

class RegExp

Object
->RegExp

native class RegExp
extends Object
Native JavaScript class RegExp.

Field Summary
native static String
native boolean
native boolean
native static String
native int
native static String
native static String
native static String
native static boolean
native static String
native String
Constructor Summary
native void
Method Summary
native void
native void
native void
Methods Inherited From Object
toString
Field Detail

$1

native static String $1

global

native boolean global

ignoreCase

native boolean ignoreCase

input

native static String input

lastIndex

native int lastIndex

lastMatch

native static String lastMatch

lastParen

native static String lastParen

leftContext

native static String leftContext

multiline

native static boolean multiline

rightContext

native static String rightContext

source

native String source
Constructor Detail

RegExp

native void RegExp()
Method Detail

compile

native void compile()

exec

native void exec()

test

native void test()

window

class String

Object
->String

native class String
extends Object
Native JavaScript class String. Includes GI extensions.

Field Summary
native void
Constructor Summary
native void
Method Summary
native void
native void
native void
String
constrainLength(intMax : ?, ellipsis : ?)
Deprecated. Use jsx3.util.strTruncate() instead.
String
doReplace(strReplace : String, strReplaceWith : String)
Deprecated. Use String.replace() with regular expression syntax.
String
doTruncate(intLength : int)
Deprecated. Use jsx3.util.strTruncate() instead.
boolean
endsWith(token : String)
Deprecated. Use jsx3.util.strEndsWith() instead.
String
Deprecated. Use jsx3.util.strEscapeHTML() instead.
String
Deprecated. Use jsx3.util.strDecodeBase64() instead.
native static void
native void
native void
native void
native void
native void
native void
native void
String
Deprecated. Use jsx3.resolveURI().
String
Deprecated. Use jsx3.util.strEncodeBase64() instead.
native void
native void
String
Deprecated. Use jsx3.util.strTrim() instead.
String
urlTo(strRelative : String)
Deprecated. Create instances of jsx3.net.URI and use URI.resolve().
Methods Inherited From Object
toString
Field Detail

length

native ? length
Constructor Detail

String

native void String()
Method Detail

charAt

native void charAt()

charCodeAt

native void charCodeAt()

concat

native void concat()

constrainLength

String constrainLength(intMax : ?, ellipsis : ?)
Deprecated. Use jsx3.util.strTruncate() instead.
trim a string down to a maximum length, put an ellipsis in the middle of the string if the string is too long, showing the beginning and ending of the string.

Parameters:

intMax
ellipsis

Returns:

 

doReplace

String doReplace(strReplace : String, strReplaceWith : String)
Deprecated. Use String.replace() with regular expression syntax.
performs a global, case-sensitive replace of all instances of @strReplace with @strReplaceWith

Parameters:

strReplacestring to replace
strReplaceWithstring to replace with

Returns:

 

doTruncate

String doTruncate(intLength : int)
Deprecated. Use jsx3.util.strTruncate() instead.
truncates a string to @intLength and appends "..." to the end if the string is is actually truncated

Parameters:

intLengthlength of the string (including the trailing ..., if necessary)

Returns:

 

endsWith

boolean endsWith(token : String)
Deprecated. Use jsx3.util.strEndsWith() instead.
Returns whether or not the string ends with @token

Parameters:

tokenitem to match on the String instance

Returns:

 

escapeHTML

String escapeHTML()
Deprecated. Use jsx3.util.strEscapeHTML() instead.
replaces the following four characters with their escaped equivalent: & < > "

Returns:

 

fromBase64

String fromBase64()
Deprecated. Use jsx3.util.strDecodeBase64() instead.
Decodes this string from its base64 equivalent.

Returns:

 

fromCharCode

native static void fromCharCode()

indexOf

native void indexOf()

match

native void match()

replace

native void replace()

search

native void search()

slice

native void slice()

split

native void split()

substring

native void substring()

toAbsolute

String toAbsolute()
Deprecated. Use jsx3.resolveURI().
takes any string (assumed to be a valid URL) and prepends that string with the appropriate path information. This function is used by the JSX framework to resolve file locations at runtime, and is always used by system methods that need to resolve the location of a resource. For example, if the application is located at "/system/JSXAPPS/app1/" and a resource is requested at "JSXAPPS/app1/components/appCanval.xml", this method would return "/system/JSXAPPS/app1/components/appCanval.xml"

Returns:

URL 

See Also:


toBase64

String toBase64()
Deprecated. Use jsx3.util.strEncodeBase64() instead.
Encodes this string to its base64 equivalent.

Returns:

 

toLowerCase

native void toLowerCase()

toUpperCase

native void toUpperCase()

trim

String trim()
Deprecated. Use jsx3.util.strTrim() instead.
trims trailing and leading spaces (anything matching the regexp, \s) from a string

Returns:

 

urlTo

String urlTo(strRelative : String)
Deprecated. Create instances of jsx3.net.URI and use URI.resolve().
Returns a url, strRelative, relative to the URL represented by this string. For example, if 'this' String is equal to "/perforce/DEV/gi/gi-dev/index.html" and @strRelative is equal to "JSXAPPS/app1/config.xml", then the result of this function would be: "/perforce/DEV/gi/gi-dev/JSXAPPS/app1/config.xml"

Parameters:

strRelativeURL to base relativity from

Returns:

 

See Also:


window

class inheritance

inheritance

class inheritance
Deprecated. Renamed to jsx3.lang.Object

See Also:

jsx3.lang.Object